Guest Posted November 18, 2004 Posted November 18, 2004 I have edited /catalog/includes/languages/danish/contest.php so that I have some phpcode in the existing php-code... Why won't this work? * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * <?php define('NAVBAR_TITLE', 'Lorum ipsum...'); define('HEADING_TITLE', 'Lorum ipsum...'); define('TEXT_CONTEST', ' <form action="contest.php" method="post"> <table border="0" cellpadding="2" cellspacing="2" class="main"> <tr> <td colspan="2" valign="bottom" class="main">Lorum ipsum...Lorum ipsum...Lorum ipsum...</td> </tr> <tr> <td valign="bottom"> </td> <td valign="bottom"></td> </tr> <tr> <td valign="bottom" class="main"><div align="left">Lorum ipsum...Lorum ipsum...Lorum ipsum...</div></td> <td valign="bottom"><p> <select name="svar" size="1" class="main"> <option selected>- Lorum ipsum...Lorum ipsum...Lorum ipsum... - <option value="1">1 <option value="2">2 <option value="3">3 <option value="4">4 <option value="5">5 <option value="6">6 <option value="7">7 <option value="8">8 <option value="9">9 <option value="10">10 </select> </p></td> </tr> <tr> <td class="main">Navn:</td> <td><input name="name" type="text"></td> </tr> <tr> <td class="main">E-mail:</td> <td><input name="email" type="text"></td> </tr> <tr> <td colspan="2" valign="top"><table border="0" cellspacing="0" cellpadding="0"> <tr> <td colspan="2" class="main">Status: <? if($navn && $email) { mail("[email protected]","Lorum ipsum...Lorum ipsum...","Svar: $svar Navn: $navn E-mail: $email"); echo("Du deltager nu i julekonkurrencen!"); } elseif ($send) { echo("Fejl - prøv igen...");} ?> </td> </tr> <tr> <td colspan="2"> </td> </tr> <tr> <td colspan="2"><div align="center"> <input type="submit" name="send" value="Send" class="buttons2"> </div></td> </tr> <tr> <td colspan="2"> </td> </tr> <tr> <td width="50%" class="main">Lorum ipsum...Lorum ipsum...Lorum ipsum...</td> <td> </td> </tr> <tr> </tr> </table></td> </table> </form>');?> * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
Guest Posted November 21, 2004 Posted November 21, 2004 The only way to execute a string as PHP code is to use eval().... http://us2.php.net/manual/en/function.eval.php
Guest Posted November 23, 2004 Posted November 23, 2004 The only way to execute a string as PHP code is to use eval().... http://us2.php.net/manual/en/function.eval.php <{POST_SNAPBACK}> Ehhhmmm, what is an eval()? I'm lost here...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.