Hi, was wondering if someone could point me in the right direction.
I am currently making a php/html registration page for users in dreamweaver and I want them to check a radio button to confirm they have read the rules, like so.

<input type="radio" name="rules" value="radiobutton">
<p>I confirm I have read the rules and agree to abide by them at all times</p>

If they haven't checked it, then I need to let them know they haven't agreed. I don't need any info sent to my database, just to ensure that they have checked it before proceeding with the registration. I have been searching for the last hour on Google with no joy for this specific request. I did read something about javascript but it was for a male/female radio button and it threw me. Any links or tips would be greatly appreciated, I know the web is a wonderful resource and perhaps I have been asking the wrong thing in my search, but I am really stuck on this. Thanks in advance.

For this thing, chekbox is what people use generally.
But u asked for radio button -

if(!isset[$_PST['radio']))
foreach ($_PST as $key =$val)
echo "$key = $val\n";

Thank you both, very helpful and much appreciated. I shall try those methods now.

i want to know about php registration schript?

Member Avatar for diafol

search the forum, about 10 threads started on this in the last 2 months.

@Xentiago:

You may want to implement some javascript to enable a disabled submit button when the checkbox is checked (an disabled once again when the checkbox is unchecked) - this may save a lot of needless action on the server - although you'll still need server-side validation.

Thank you ardav, makes sense really. I shall give that a go.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.