Bonjour,
J'ai une fonction en JS :
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
| function navigateur()
{
navigateur = navigator.appName;
if (navigateur == "Microsoft Internet Explorer")
{
style = "position:absolute; border-style: solid; border-color: green; margin-top:10px; margin-left:175px; width:900px; height:600px";
}
else
{
style = "position:absolute; border-style: solid; border-color: green; margin-top:15px; margin-left:145px; width:900px; height:600px";
}
return style;
} |
Je souhaite ensuite récupérer la chaine style dans la balsie Style
<div id="centre" style="navigateur();">
Mais ça ne fonctionne pas !
Merci pour votre aide.
PIL
Partager