Page 1 of 1

php not picking up a variable

Posted: Thu Jul 10, 2003 8:45 pm
by m3rajk
code in use: http://people.brandeis.edu/~m3rajk/JMT/ ... signup.php
code minus opening <?php: http://people.brandeis.edu/~m3rajk/JMT/ ... signup.txt

main issue (only one that MUST be resolved): php is not picking up the variable step in the submission of the 4th step.
function that creates the 4th step:

Code: Select all

<?php
function s4(){
  ?>      <h1>THIS IS A TEST. IT DOES NOT HAVE A DATABASE CONNECTION NOR DOES IT CHECK USERNAMES. THIS LINE WILL BE REMOVED IN THE REAL ONE </h1>
      
      <p>Thank you for your interest in joining FindYourDesire.com. We need to know some things about you in order to make your profile here. Any feild in <font color="#ff0000">RED</font> is required. Any feild marked with an * is confidential and will NOT show up in your user stats. Any feild with a &#176; will not show up in your user stats, but is collected for future features. You will be notified before they are used.</p>
      <h2>NOTE: MAXIMUM PICTURE SIZE IS 150 KB</h2>
      <form enctype="multipart/form-data" action="<?php echo $_SERVER[PHP_SELF]; ?>" method="POST">
	<input type="hidden" name="step" value="5"><input type="hidden" name="MAX_FILE_SIZE" value="153600">
	<table frame="void" bgcolor="#000000" border="0" cellpadding="0" cellspacing="0" text="#c8c8c8">
	    <tr><td>Your <a name="#confcode" href="#confcode" onClick="window.open('faq.php?seek=confcode', 'faq', 'width=500,height=250,scrollbars=yes');">Confirmation Code</a></td><td><input type="text" name="conf" size="25"></td></tr>
	    <tr><td>Upload your main picture</td><td><input type="file"  accept="image/jpeg" name="main" size="25"></td></tr>
	    <tr><td>Upload Thumb 1</td><td><input type="file"  accept="image/jpeg" name="t1" size="25"></td></tr>
	    <tr><td>Upload Thumb 2</td><td><input type="file"  accept="image/jpeg" name="t2" size="25"></td></tr>
	    <tr><td>Upload Thumb 3</td><td><input type="file"  accept="image/jpeg" name="t3" size="25"></td></tr>
	    <tr><td>Upload Thumb 4</td><td><input type="file"  accept="image/jpeg" name="t4" size="25"></td></tr>
	    <tr><td>Upload your <a name="#salute" href="#salute" onClick="window.open('faq.php?seek=salute', 'faq', 'width=500,height=250,scrollbars=yes');">salute</a></td><td><input type="file"  accept="image/jpeg" name="salute" size="25"></td></tr>
	    <tr><td><input type="submit" value="Go To The Next Step"></td><td><input type="reset" value="Restart This Step"></td></tr>
	</table>
    </center>
  </body>
</html>
 <?php
}?>
thanx in advance for your insight.

-m3rajk

Posted: Fri Jul 11, 2003 2:09 am
by Tubbietoeter
1.) close the <form> tag and see if it works out then ...

2.) if the regular expressions got /^ at the beginning and $/ at the end, it has to match the whole string.