recuperer une variable d'une fonction js
bjs, j'ai une fonction activé par un onclick:
Code:
1 2 3 4 5 6 7 8 9 10 11
| function nomfichepersoen(nom)
{
if(nom!='')
{
document.getElementById("fiche_ennemis").style.display = 'block';
}
else
{
document.getElementById("fiche_ennemis").style.display = 'none';
}
} |
cette fonction affiche ou non un div.
quand celui-ci s'affiche voici se qu'il contient:
Code:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21
| <DIV id="fiche_ennemis" style="display:none;">
<table border="0" cellpadding="0" cellspacing="0">
<tr>
<td id="objhautgauche"> </td>
<td id="objhaut"><font class="h">Fiche perso Ennemis:</font></td>
<td id="objhautdroite"> </td>
</tr>
<tr>
<td id="objgauche"> </td>
<td id="obj">
<iframe name="fiche_ennemis" src="menu_ficheennemis.php?action=1&nom=ICI il faudrais le "nom" de la fonction donner plus haut" id="fiche_ennemis"></iframe>
</td>
<td id="objdroite"> </td>
</tr>
<tr>
<td id="objbasgauche"> </td>
<td id="objbas"> </td>
<td id="objbasdroite"> </td>
</tr>
</table>
</DIV> |