Php / include

Bonjour,

J'ai un vrai problème d'include. En fait j'ai deux pages php dont une qui fait appel à l'autre à différents endroits.
Le problème c'est qu'une fonction est donc appelé plusieurs fois et j'obtiens l'erreur : Fatal error: Cannot redeclare mafonction()
Comment est ce que je peux faire pour ne plus avoir cette erreur.

Merci.
Configuration: Windows XP
Firefox 3.0.1

1 réponse

  1. Deja poste nous ton code
    0
    1. voilà:
      include 'function.php'
      for ($Index_gauche=0;$Index_gauche<ceil($lngIndex/2);$Index_gauche++){
      ?>
      <table width="400">
      <tr valign="top">
      ...
      </td>
      </tr>
      <tr>
      <td colspan="3" class="lightBlueBg"></td>
      </tr>
      </table>
      <?
      }
      ?>
      </td>

      <tr>
      <td valign="top">
      <?

      include 'function.php'
      for ($Index_droite>=ceil($lngIndex/2);$Index_droite<$lngIndex;$Index_droite++) {
      ?>
      <table width="400">

      </tr>
      <tr>
      <td colspan="3" class="lightBlueBg"></td>
      </tr>
      </table>
      <?
      }
      ?>
      </td>
      </tr>
      </table>
      0