Jump to content

Issue showing/hiding form


dminder

Recommended Posts

First let me state my goal: I have a Terms of use page that I want to use two-fold - 1) for a terms of use for general consumption 2) as a pre-registration page that they at least have to click on an acknowledgment of the terms before actually registering. That being said, I am having problems with the page not loading correctly.The registration url is setup like this: http://www.mysite.com/registration.php?r=1 and the non-registration does not have the ?r=1 on the end of it. SO, if the user clicks on the first URL, it directs them to the page and is supposed to SHOW them the following:

<div>	 MY TERMS OF USE TEXT WHICH IS VERY VERY LONG</div><br /><?php		$r=$_GET['r'];		IF($r==1){?>					<form id="terms" name="terms" method="post" action="registeruser.php">						<input type="checkbox" name="acceptterms" id="acceptterms"  							onclick="enable_submit(this.checked)"> I accept and agree to the terms of use.  						<input type="submit" id="regnext" name="regnext" value="Next">					</form>	 <?php } else { echo("" .$r); ?>

The problem is that the form will not show up on either page. Oh and I added the "<?php } else { echo("" .$r); ?>" as a test to see if it was hitting it and I still get nothing.Am I going about this the wrong way? Have I made an error in my code? Please help before I lose what little sanity that I have remaining!!!Thanks,D

Link to comment
Share on other sites

Ok, yes that would solve the issue (and probably will do that) and is the most obvious. However, from a coding standpoint, what am I doing wrong to show/hide a section of code? I would really like to know what is wrong with the code so that I can learn and be a better developer!!Thank you for your response wirehopper, it is muchly appreciated!!D

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...