problem with "Agree To Terms" button

  • 1
  • Question
  • Updated 9 years ago
  • Answered
I am having a problem with "Agree To Terms" button that i am checking out. It doesn't matter if you select "agree". It still goes to the page. I am using FF and haven't tried IE yet
Here is the code:

//Paste this code into the BODY section of your HTML document

I accept:

-->

Here is my site testpager.yolasite.com and select "accept terms" page

Thanks in advance,
Harry
Photo of Harry

Harry

  • 82 Posts
  • 0 Reply Likes
  • confused

Posted 9 years ago

  • 1
Photo of lambofgod

lambofgod

  • 875 Posts
  • 35 Reply Likes
Hello Harry,

This should work. Tell me if you have any problems. Don't copy the <!-- and-->

<!--
<SCRIPT language=JavaScript>

function checkCheckBox(f){
if (f.agree.checked == false )
{
alert('Please check the box to continue.');
return false;
}else
return true;
}

</SCRIPT>

<form action="/yourscript.cgi-or-your-page.html" method="GET" onsubmit="return checkCheckBox(this)">

<b>By submitting, I agree that all info entered was done accurately & truthfully.</b><br />
I accept: <input type="checkbox" value="0" name="agree">
<input type="submit" value="Submit form">
<input type="button" value="Exit" onclick="document.location.href='/index.html';">
</form>
-->

Just enter the pages you want the form to go. Message back if you need any help.
Photo of Emmy

Emmy

  • 5892 Posts
  • 299 Reply Likes
Wonderful, thanks lambofgod!

Emmy
Photo of Harry

Harry

  • 82 Posts
  • 0 Reply Likes
That did it.

Thanks
Photo of lambofgod

lambofgod

  • 875 Posts
  • 35 Reply Likes
Glad everything worked out ok.
Photo of Harry

Harry

  • 82 Posts
  • 0 Reply Likes
Can that code be modified so it can be use for multiple pages. Or do I copy and change some stuff to work for their dedicated pages?
Photo of lambofgod

lambofgod

  • 875 Posts
  • 35 Reply Likes
Yes you can have that code on different pages. Don't hesitate to ask me if you have any problems.
Photo of Harry

Harry

  • 82 Posts
  • 0 Reply Likes
It is hard for me to explain.So from what I understand I cannot use one code for all pages. Look at my page pawilderness.yolasite.com/hunting.php. Half way down, you will see a drop down (Squirrel is the first selection). The code is working for the squirrel page. Now do I have to write a code for each page or is there a way so when ever they select from the menu they are automatically taken to the terms page then redirected to the page they want? I hpoe you understood that, because I sure didn't
Photo of Sanja

Sanja, Official Rep

  • 10698 Posts
  • 495 Reply Likes
Hi Harry.. it's because you did not enter the same href tag. Also, I assume you will need to create a new term page for each section. So that when the user clicks on "enter site", they are redirected to the page they want. So, for your grouse one, you will need to create a new term page (still same content), but your submit button will have the new redirect link.

See take a look:
value="http://pawilderness.yolasite.com/term...

Your squirrel one has the term.php. The grouse one does not. So, you'll need to create a new sub-page entitled term1.php and then link to that. Then, on the submit button, change the url to the grouse page.

Does that make sense?
Photo of Harry

Harry

  • 82 Posts
  • 0 Reply Likes
That is what I thought I had to do. Create a terms page for each page. I only put terms on the squirrel page to test.

Thanks
Photo of Harry

Harry

  • 82 Posts
  • 0 Reply Likes
littleus,
do you remeber the sound mouseover problem I had? If I copied the code and replaced the picture and sound IN THE CODE, it should work, right?
I tried but the picture does not show. And there is no sound (tried with and without sound fx)

Thanks
Photo of Harry

Harry

  • 82 Posts
  • 0 Reply Likes
picture and sound are both in file manager
Photo of Sanja

Sanja, Official Rep

  • 10698 Posts
  • 495 Reply Likes
You just need to make sure that the file name you used for your picture and your sound in the code is the same as what have in your file manager. File names are also case sensitive.
Photo of Harry

Harry

  • 82 Posts
  • 0 Reply Likes
It seems to be a picture problem. I tried three different pics before it would show the pic. Sound is ok too. I quess I will have to get different pics.
Photo of Sanja

Sanja, Official Rep

  • 10698 Posts
  • 495 Reply Likes
You shouldn't have to get new pictures though. After you've uploaded your new picture into your file manager. Sometimes, it helps to update your site 1st. Then, add in your new code.
Photo of Harry

Harry

  • 82 Posts
  • 0 Reply Likes
littleus,
I forgot a very important piece of the puzzle. Using - /resours...../Mypic.jpg instead of /resours.../Animal_Pictures/Mypic.jpg

if you would not mind. Can u go to my site and go to squirrel page, look under gray squirrel picture and see if the "put mouse......see picture" code it working. I am using FF. when I use IE the some of the pages look different (ex. centered not centered). But that I can work around right now.

Thanks
Photo of Sanja

Sanja, Official Rep

  • 10698 Posts
  • 495 Reply Likes
Yep.. you need to make sure you include all the subfolders. Good for you for catching that! =) It all works!

Although, I have to admit, unless you're going to enlarge the photo of the squirrel, or else make the photo a thumbnail size, I would say there's probably no point on clicking to see a picture which is the exactly the same one. if you decide to keep your idea of clicking on the photo, I would suggest that you add a target="_blank" after your a href tag to make your photo open up on a new page instead of the same window.
Photo of Harry

Harry

  • 82 Posts
  • 0 Reply Likes
by the way, updating and then add code worked. I am going to DO IT everytime I add a new code. Of course on my test page first to make sure it is the way I want it..
Photo of Harry

Harry

  • 82 Posts
  • 0 Reply Likes
if i don't want to show pic, do i take out the href and just keep the mouseover
Photo of Sanja

Sanja, Official Rep

  • 10698 Posts
  • 495 Reply Likes
If you don't want the link to go to your picture, then yes... all you have to do is remove that a href tag to your image.
Photo of Harry

Harry

  • 82 Posts
  • 0 Reply Likes
for now, if you "click" on....., the squirrel page refreshes or reloads
Photo of Sanja

Sanja, Official Rep

  • 10698 Posts
  • 495 Reply Likes
I'm not sure I understand Harry. I see that you've removed the link to your photo. The sound link still works great!