Aficher un menu javascripte dans un theme php

Fermé
reno915 Messages postés 1 Date d'inscription mercredi 29 avril 2009 Statut Membre Dernière intervention 29 avril 2009 - 29 avril 2009 à 16:34
moulesfrites Messages postés 25 Date d'inscription mercredi 22 avril 2009 Statut Membre Dernière intervention 29 mai 2009 - 30 avril 2009 à 18:14
Bonjour, Bonsoir a tous

j'ai récupéré et modifié bon petit menu en Javascript pour mon site :
www.airsoftpascher.com/APC

mais je n'arrive pas a l'afficher dans mon theme Php. lorque j'ai fait le tableau aux dimensions la position c'est afficher mais pas le menu.

mon code pour le theme :
<table width=\"1024\" height=\"40\" border=\"0\" cellpadding=\"0\" cellspacing=\"0\">
<tr>
<td><script language=javascript type=text/javascript src=ejs_menu_multicolor.js>
</script><noscript><a href=\"http://www.editeurjavascript.com/mycircle\">echange de lien</a></noscript></td>
</tr>
</table>
( !


Il y a t'il une ligne de code a rajouté pour que celui-ci s'affiche ?

la page du menu (je pense pas nécessaire) :
// http://www.editeurjavascript.com/for...7,39784,0.html
// http://www.editeurjavascript.com/scr...tion_1_111.php
bgcolor='#FFFFFF';
bgcolor0='#E9967A'; //CC0000';
bgcolor1='#FF69B4'; //CC0000';
bgcolor2='#FF6347'; //CC0000';
bgcolor3='#48D1CC'; //CC0000';
bgcolor4='#FFA500'; //CC0000';
bgcolor5='#BC8F8F'; //CC0000';
bgcolor6='#00FF00'; //CC0000';
bgcolor7='#FFB6C1'; //CC0000';
bgcolor8='#D2691E'; //CC0000';
bgcolor9='#ADFF2F'; //CC0000';

zgcolor = new Array;
zgcolor[0] = '#E9967A'; //CC0000';
zgcolor[1] = '#FF69B4'; //CC0000';
zgcolor[2] = '#FF6347'; //CC0000';
zgcolor[3] = '#48D1CC'; //CC0000';
zgcolor[4] = '#FFA500'; //CC0000';
zgcolor[5] = '#BC8F8F'; //CC0000';
zgcolor[6] = '#00FF00'; //CC0000';
zgcolor[7] = '#FFB6C1'; //CC0000';
zgcolor[8] = '#D2691E'; //CC0000';
zgcolor[9] = '#ADFF2F'; //CC0000';

document.write('<style type="text/css">');
document.write('.popper { POSITION: absolute; VISIBILITY: hidden; z-index:3; }')
document.write('#topgauche { position:absolute; z-index:10; }')
document.write('A:hover.ejsmenu {color:#000000; text-decoration:none;}')
document.write('A.ejsmenu {color:#000000; text-decoration:none;}')
document.write('</style>')
document.write('<div style="position:relative;height:25"><DIV class=popper id=topdeck></DIV>');
/*
SCRIPT EDITE SUR L'EDITEUR JAVACSRIPT
http://www.editeurjavascript.com
*/

/*
LIENS
*/

zlien = new Array;
zlien[0] = new Array;
zlien[1] = new Array;
zlien[2] = new Array;
zlien[3] = new Array;
zlien[4] = new Array;
zlien[5] = new Array;
zlien[6] = new Array;
zlien[0][0] = '<A HREF="index.php?file=Boutique&op=cat&catid=1" CLASS=ejsmenu>AEG</A>';
zlien[0][1] = '<A HREF="index.php?file=Boutique&op=cat&catid=17" CLASS=ejsmenu>Fusil Sniper</A>';
zlien[0][2] = '<A HREF="index.php?file=Boutique&op=cat&catid=31" CLASS=ejsmenu>Pistolets (GBB/AEP)</A>';
zlien[0][3] = '<A HREF="index.php?file=Boutique&op=cat&catid=60" CLASS=ejsmenu>Fusils a pompe</A>';
zlien[0][4] = '<A HREF="index.php?file=Boutique&op=cat&catid=28" CLASS=ejsmenu>Chargeurs</A>';
zlien[0][5] = '<A HREF="index.php?file=Boutique&op=cat&catid=4" CLASS=ejsmenu>Stock de Billes</A>';
zlien[0][6] = '<A HREF="index.php?file=Boutique&op=cat&catid=3" CLASS=ejsmenu>Protections</A>';
zlien[0][7] = '<A HREF="index.php?file=Boutique&op=cat&catid=2" CLASS=ejsmenu>Pièces et Accessoires</A>';
zlien[0][8] = '<A HREF="index.php?file=Boutique&op=cat&catid=44" CLASS=ejsmenu>Article Update</A>';
zlien[1][0] = '<A HREF="index.php?file=News" CLASS=ejsmenu>Les Nouveautées</A>';
zlien[1][1] = '<A HREF="index.php?file=Archives" CLASS=ejsmenu>Les Archives</A>';
zlien[2][0] = '<A HREF="index.php?file=Forum" CLASS=ejsmenu>Forum</A>';
zlien[2][1] = '<A HREF="index.php?file=Contact" CLASS=ejsmenu>Contact</A>';
zlien[2][2] = '<A HREF="index.php?file=Page&name=conact_mails" CLASS=ejsmenu>Nos mails</A>';
zlien[3][0] = '<A HREF="index.php?file=Page&name=Airsoft" CLASS=ejsmenu>Qu"est ce que l"airsoft ?</A>';
zlien[3][1] = '<A HREF="index.php?file=Page&name=valeur_sur" CLASS=ejsmenu>Valeurs sur en Cheap</A>';
zlien[3][2] = '<A HREF="index.php?file=Page&name=review" CLASS=ejsmenu>Liste de Review</A>';
zlien[3][3] = '<A HREF="index.php?file=Page&name=billes" CLASS=ejsmenu>Billes? Les différences ?</A>';
zlien[3][4] = '<A HREF="index.php?file=Page&name=reportage" CLASS=ejsmenu>Reportage sur l"Airsoft</A>';
zlien[3][5] = '<A HREF="index.php?file=Page&name=FPS" CLASS=ejsmenu>Convertisseur FPS/Joules</A>';
zlien[3][6] = '<A HREF="index.php?file=Page&name=Reglementation" CLASS=ejsmenu>Réglementation sur l"Airsoft (La LOI)</A>';
zlien[4][0] = '<A HREF="index.php?file=Page&name=quisommesnous" CLASS=ejsmenu>Qui sommes nous ?</A>';
zlien[4][1] = '<A HREF="index.php?file=Page&name=paypal" CLASS=ejsmenu>Paiement Ultra-sécurisé</A>';
zlien[4][2] = '<A HREF="index.php?file=Page&name=poste" CLASS=ejsmenu>Infos Livraisons</A>';
zlien[4][2] = '<A HREF="index.php?file=Boutique&op=cgv" CLASS=ejsmenu>Conditions Générales de vente</A>';
zlien[4][3] = '<A HREF="index.php?file=Page&name=partenaire" CLASS=ejsmenu>Partenariat</A>';
zlien[5][0] = '<A HREF="index.php?file=Faqs" CLASS=ejsmenu>F.A.Q.s</A>';
zlien[5][1] = '<A HREF="index.php?file=Links" CLASS=ejsmenu>Association/Team</A>';
zlien[5][2] = '<A HREF="index.php?file=Boutique&op=cgv" CLASS=ejsmenu>Conditions Générales de vente</A>';

var nava = (document.layers);
var dom = (document.getElementById);
var iex = (document.all);
if (nava) { skn = document.topdeck }
else if (dom) { skn = document.getElementById("topdeck").style }
else if (iex) { skn = topdeck.style }
skn.top = 24;

function pop(msg,pos)
{
skn.visibility = "hidden";
a=true
skn.left = pos;
var content ="<TABLE BORDER=0 CELLPADDING=0 CELLSPACING=0 BGCOLOR=#000000 WIDTH=150><TR><TD><TABLE WIDTH=100% BORDER=0 CELLPADDING=0 CELLSPACING=1>";
pass = 0
while (pass < msg.length)
{
content += "<TR><TD BGCOLOR="+bgcolor+" onMouseOver=\"this.style.background='"+zgcolor[pass]+"'\" onMouseOut=\"this.style.background='"+bgcolor+"'\" HEIGHT=20><FONT SIZE=1 FACE=\"Verdana\"> "+msg[pass]+"</FONT></TD></TR>";
pass++;
}
content += "</TABLE></TD></TR></TABLE>";
if (nava)
{
skn.document.write(content);
skn.document.close();
skn.visibility = "visible";
}
else if (dom)
{
document.getElementById("topdeck").innerHTML = content;
skn.visibility = "visible";
}
else if (iex)
{
document.all("topdeck").innerHTML = content;
skn.visibility = "visible";
}
}

function kill()
{
skn.visibility = "hidden";
}

document.onclick = kill;
document.write('<DIV ID=topgauche><TABLE BORDER=0 CELLPADDING=0 CELLSPACING=0 BGCOLOR=#000000 WIDTH=1024><TR><TD><TABLE CELLPADING=0 CELLSPACING=1 BORDER=0 WIDTH=100% HEIGHT=25><TR>')
document.write('<TD WIDTH=145 ALIGN=center BGCOLOR='+bgcolor+' onMouseOver="this.style.background=\''+bgcolor2+'\';pop(zlien[0],0)" onMouseOut="this.style.background=\''+bgcolor+'\'"><img src="http://www.airsoftpascher.com/images/ico01.JPG" width="10" height="10"><A onClick="return(false)" onMouseOver="pop(zlien[0],0)" href=# CLASS=ejsmenu><FONT SIZE=1 FACE="Verdana">BOUTIQUE</FONT></a></TD>')
document.write('<TD WIDTH=145 ALIGN=center BGCOLOR='+bgcolor+' onMouseOver="this.style.background=\''+bgcolor3+'\';pop(zlien[1],146)" onMouseOut="this.style.background=\''+bgcolor+'\'"><A onClick="return(false)" onMouseOver="pop(zlien[1],115)" href=# CLASS=ejsmenu><FONT SIZE=1 FACE="Verdana"> NOUVEAUTEES</FONT></a></TD>')
document.write('<TD WIDTH=145 ALIGN=center BGCOLOR='+bgcolor+' onMouseOver="this.style.background=\''+bgcolor4+'\';pop(zlien[2],292)" onMouseOut="this.style.background=\''+bgcolor+'\'"><A onClick="return(false)" onMouseOver="pop(zlien[2],290)" href=# CLASS=ejsmenu><FONT SIZE=1 FACE="Verdana"> CONTACT</FONT></a></TD>')
document.write('<TD WIDTH=145 ALIGN=center BGCOLOR='+bgcolor+' onMouseOver="this.style.background=\''+bgcolor5+'\';pop(zlien[3],437)" onMouseOut="this.style.background=\''+bgcolor+'\'"><A onClick="return(false)" onMouseOver="pop(zlien[3],400)" href=# CLASS=ejsmenu><FONT SIZE=1 FACE="Verdana"> ARTICLES</FONT></a></TD>')
document.write('<TD WIDTH=145 ALIGN=center BGCOLOR='+bgcolor+' onMouseOver="this.style.background=\''+bgcolor6+'\';pop(zlien[4],583)" onMouseOut="this.style.background=\''+bgcolor+'\'"><A onClick="return(false)" onMouseOver="pop(zlien[4],500)" href=# CLASS=ejsmenu><FONT SIZE=1 FACE="Verdana"> AIRSOFT PAS CHER</FONT></a></TD>')
document.write('<TD WIDTH=145 ALIGN=center BGCOLOR='+bgcolor+' onMouseOver="this.style.background=\''+bgcolor7+'\';pop(zlien[5],729)" onMouseOut="this.style.background=\''+bgcolor+'\'"><A onClick="return(false)" onMouseOver="pop(zlien[5],600)" href=# CLASS=ejsmenu><FONT SIZE=1 FACE="Verdana"> QUESTIONS ?</FONT></a></TD>')
document.write('<TD WIDTH=145 ALIGN=center BGCOLOR='+bgcolor+' onMouseOver="this.style.background=\''+bgcolor8+'\';pop(zlien[6],870)" onMouseOut="this.style.background=\''+bgcolor+'\'"><A onClick="return(false)" onMouseOver="pop(zlien[6],700)" href=# CLASS=ejsmenu><FONT SIZE=1 FACE="Verdana"> AUTRES</FONT></a></TD>')
document.write('</TR></TABLE></TD></TR></TABLE></DIV></div>')
A voir également:

1 réponse

moulesfrites Messages postés 25 Date d'inscription mercredi 22 avril 2009 Statut Membre Dernière intervention 29 mai 2009
30 avril 2009 à 18:14
Bonjour, fais fonctionner le script suivant il devrait d'inspirer pour t'aider avec du javascript

<html>
<head>
<title>exemple de var javasript vers $ php en boucle</title>
<script language="JavaScript">
function numeros() {
var tableau=new Array();
for(i=0;i<7;i++) {
tableau[i]=i;}
for(i=0;i<7;i++) {
nomchamp="boule"+i;
instruction="document.form1."+nomchamp+".value=tableau[i]";
eval(instruction);
} }
</script>
</head>
<body>
<form name="form1" method="post" action="">
<?php $az='' ; $x='' ;
for($x=0;$x<7;$x++){
$az='<input size="2" name="boule'.$x.'" value="100" type="text" />' ;
echo $az ; } ?>
<input type="button" name="Submit" value="exemple de var javasript vers $ php en boucle" onMouseMove="numeros()">
</form>
</body>
</html>
0