Go Back   PHP Link Directory Forum > PHP Link Directory (phpLD) > Mods and contribution Discussion

Mods and contribution Discussion This forum is only for discussion of modding phpLD. For specific mod releases, please see the appropriate forum.

Closed Thread
 
Thread Tools Display Modes
Old 02-07-2006   #1
Neticus
Supporter
 
Neticus's Avatar
 
Join Date: Dec 2005
Posts: 487
Default Accept 'Terms of Agreement' checkbox

Have just done this myself thought i'd share

Adding 'Accept Agreement' checkbox to submit form.
Form will not submit until user checks this box.


In submit.tpl

Near top, Replace:

Code:
<form method="post" action="">
with

Code:
<form method="post" action="" onsubmit="return checkCheckBox(this)">


Scroll down to end of file, Replace:

Code:
<td colspan="2" class="buttons"><input type="submit" name="submit" value="{l}Continue{/l}" class="btn"/></td>
with

Code:
<td colspan="2" class="buttons">
Accept Terms of Agreement <input type="checkbox" value="0" name="agree">

<input type="submit" name="submit" value="{l}Continue{/l}" class="btn">


<input type="button" value="Exit" class="btn" onclick="document.location.href='/index.php';"/></td>
This code in above is optional:
<input type="button" value="Exit" class="btn" onclick="document.location.href='/index.php';"/>

class="btn" sets button colour.


3. Just before {include file="footer.tpl"} place:

Code:
{* Javascript for Accept Terms of Agreement box *}

{literal}
<script>
<!-- Begin
function checkCheckBox(f){
if (f.agree.checked == false )
{
alert('You must tick box to continue.');
return false;
}else
return true;
}
//  End -->
</script>

{/literal}

_
Neticus is offline  
Old 02-07-2006   #2
David
Administrator
phpLD Administrator
Supporter
 
David's Avatar
 
Join Date: Jan 2005
Posts: 11,667
Default

Wow! Thanks for sharing.
David is offline  
Old 02-08-2006   #3
Sxperm
Supporter
 
Join Date: Dec 2005
Posts: 154
Send a message via ICQ to Sxperm Send a message via MSN to Sxperm
Default

Thank you very much for your contribution :lol: and thanks again for your PM :wink:

Cheers,
Sxperm
__________________
Real Estate Directory Online - EstateRound.com

Submit your real estate resources for free (with reciprocal) or $19 for listing.

Real Estate Listings - 2found.com
Sxperm is offline  
Old 02-08-2006   #4
Kevuk2k
 
Join Date: Jan 2006
Location: Global
Posts: 567
Send a message via MSN to Kevuk2k
Default Re: Accept 'Terms of Agreement' checkbox

Quote:
Originally Posted by Neticus
Have just done this myself thought i'd share

Adding 'Accept Agreement' checkbox to submit form.
Form will not submit until user checks this box.
An excellent idea, however I've just been testing it and put in verbatim your instructions. I managed to bypass the tick box and still went straight to the paypal processing. The only thing that ever stopped me is the sheer power of the script itself, i.e if you dupe your submission, parent already exists, you get the captcha wrong, the only thing that did not work no matter what was the javascript you made? I followed your guidance to the letter and even had a tech of mine to do it and it wasn't me for a change? Any ideas?

Cracking idea, however it might be a better idea to put a terms of service page online first and to hyperlink this in a pop up box so that the submittor knows the TOS he/she is agreeing to. I'd like to see this working though. Well done on the concept even if it didn't work for me. Not to blow the candle out though all a person has to do is to write a line of text stating...
Quote:
By completing this form you are accepting the terms and conditions of this site.
Sometimes comlicating the uncomplicated doesn't always work, but does give food for thought as we now know we all should have considered this earlier. Thankyou very much for contributing.

Kevin
Kevuk2k is offline  
Old 02-08-2006   #5
Neticus
Supporter
 
Neticus's Avatar
 
Join Date: Dec 2005
Posts: 487
Default

Sorry it didn’t work for you I‘ve just reinstalled it again on an affected and unaffected submit.tpl and it seems to hold the fort.

You could do like I did, go to a forum, kindly ask how X is achieved, you may have someone give you a different code to attempt.
Then try to incorporate into the relevant areas of submit.tpl.

However if it helps it may be a browser incompatibility problem I’m an IE6 user.

As for linking to the Terms of Agreement you could make the text a link that opens in a new window to - terms.php i.e.

To incorporate the terms into a customized pop up window you may have to use a 'window generator' script. Just search for that as a keyword.

Although Plan B works too. Just write it.

Peace.
Neticus is offline  
Old 02-08-2006   #6
Kevuk2k
 
Join Date: Jan 2006
Location: Global
Posts: 567
Send a message via MSN to Kevuk2k
Default

Quote:
Originally Posted by Neticus
Sorry it didn’t work for you I‘ve just reinstalled it again on an affected and unaffected submit.tpl and it seems to hold the fort.

You could do like I did, go to a forum, kindly ask how X is achieved, you may have someone give you a different code to attempt.
Then try to incorporate into the relevant areas of submit.tpl.

However if it helps it may be a browser incompatibility problem I’m an IE6 user.

As for linking to the Terms of Agreement you could make the text a link that opens in a new window to - terms.php i.e.

To incorporate the terms into a customized pop up window you may have to use a 'window generator' script. Just search for that as a keyword.

Although Plan B works too. Just write it.

Peace.
Humble pie Gladly eaten!!! ops: The script worked absolutely fine in internet explorer all versions, opera, firefox and a few others so far.... Was a syntax error not being picked up as a result of inncorrect installation of your description. Still think this is not really needed but is definately an added bonus to any site that wants to make 110% certain the tos has been accepted. No comebacks then.

10/10 and my humble apologies for claiming it didn't work for me....


Scriptwriting is not my forte, but intillectual property is :wink:

Thanks,

Kevin
Kevuk2k is offline  
Old 02-08-2006   #7
Bill
Mentor
 
Bill's Avatar
 
Join Date: Aug 2005
Location: New Jersey
Posts: 334
Default

Hey, sounds great! Do you have a demo?
Bill is offline  
Old 02-08-2006   #8
Kevuk2k
 
Join Date: Jan 2006
Location: Global
Posts: 567
Send a message via MSN to Kevuk2k
Default

Quote:
Originally Posted by microdude431
Hey, sounds great! Do you have a demo?
Kevuk2k is offline  
Old 02-08-2006   #9
Neticus
Supporter
 
Neticus's Avatar
 
Join Date: Dec 2005
Posts: 487
Default

Quote:
Originally Posted by Kevuk2k
You can see the demo here...

It works now too!
Cool, glad it finally worked out. :)

Like I said if you're planning to do a separate Terms page you can link to it with the following, it opens it up in a new window.

Code:
By ticking the box you confirm you are accepting our Terms of Agreement
_

Neticus

Last edited by David; 03-06-2008 at 07:30 PM.
Neticus is offline  
Old 02-09-2006   #10
Kevuk2k
 
Join Date: Jan 2006
Location: Global
Posts: 567
Send a message via MSN to Kevuk2k
Default

Quote:
It works now too
Cool, glad it finally worked out.

Like I said if you're planning to do a separate Terms page you can link to it with the following, it opens it up in a new window.

Code:
By ticking the box you confirm you are accepting our Terms of Agreement
_

Neticus[/quote]

Thanks, I may be dumb, but not that dumb!! :lol:

Kev
Kevuk2k is offline  
Old 05-08-2006   #11
Steven Myers
Supporter
 
Steven Myers's Avatar
 
Join Date: May 2006
Posts: 1,178
Default

This mod worked limk a charm! thank you David!
__________________
Hosting Feedback - General Web Directory
Steven Myers is offline  
Old 05-08-2006   #12
Optimit
Supporter
 
Join Date: Dec 2005
Posts: 1,247
Default

Is this working on 3.04?
Optimit is offline  
Old 05-08-2006   #13
Neticus
Supporter
 
Neticus's Avatar
 
Join Date: Dec 2005
Posts: 487
Default

I haven't tried it with 3.04 yet. However I've just looked at the 3.04 code in submit.tpl, the relevant lines to edit are still there so it should work.
Neticus is offline  
Old 05-08-2006   #14
css59
Supporter
 
Join Date: Mar 2006
Location: USA
Posts: 352
Default

Quote:
Originally Posted by Neticus
I haven't tried it with 3.04 yet. However I've just looked at the 3.04 code in submit.tpl, the relevant lines to edit are still there so it should work.
If someone tests in 3.0.4 please let us know if it works
__________________
http://linkageplus.com - clean - PR5 - general directory
http://webdirectoryforums.com - Add your directory free and advertise in the forums free!
http://cardraft.com - car link directory

http://www.phplinkdirectory.com/foru...ad.php?t=13493 - Post if you want added to my list of free phpld sites
css59 is offline  
Old 05-09-2006   #15
neurosis4u
Moderator
 
neurosis4u's Avatar
 
Join Date: Mar 2006
Location: Germany
Posts: 1,056
Send a message via MSN to neurosis4u Send a message via Yahoo to neurosis4u
Default

Quote:
Originally Posted by css59
If someone tests in 3.0.4 please let us know if it works
it works on 3.04
__________________
If you want to make me happy, send much money with PayPAl to: admin(@)ohneschufaweb.de
Mein Spendenkonto ist bei PayPal zu erreichen: admin(@)ohneschufaweb.de

http://www.ohneschufaweb.de


neurosis4u is offline  
Old 06-02-2006   #16
aspidov
 
aspidov's Avatar
 
Join Date: Mar 2006
Posts: 258
Default

works perfect with 3.05 as well
aspidov is offline  
Old 07-13-2006   #17
GimmeMyDomains
Supporter
 
Join Date: Jun 2006
Posts: 37
Default TOU

Nice - works great. Now, does anyone have a "Terms and Conditions of Use" that I can use as a starting point?
GimmeMyDomains is offline  
Old 07-20-2006   #18
kentuckyslone
 
Join Date: May 2006
Posts: 66
Default

Thanks for that code! Until I actually write up a separate terms page I am using this to ask the submitter to confirm that they have read and agree to the submission guidelines. I figured that was just about the same as terms.
kentuckyslone is offline  
Old 08-26-2006   #19
mmastation
Mentor
Supporter
 
mmastation's Avatar
 
Join Date: May 2006
Location: San Diego, California
Posts: 523
Default

anyone have the mod to add an extra box to the submit page? like next to where they fill everything out? so I can put terms of service and such in that.
mmastation is offline  
Old 01-06-2007   #20
jojomart
 
jojomart's Avatar
 
Join Date: Aug 2005
Location: Nova Scotia, Canada
Posts: 142
Send a message via MSN to jojomart
Default Will this work with version 3.1?

Hi, I'd like to use this mod, but I'm wondering if it will work with version 3.1.

I can't find the
Code:
 <form method="post" action="">
in my submit.tpl file.

Here's what I have:

Code:
 <form method="post" action="submit.php">
Thanks in advance,

Joanne
__________________
Wannaberichtoo Web Directory
http://www.wannaberichtoowebdirectory.info

{broken url removed}

Wallpaper Downloads
http://www.wallpaper-downloads.info
jojomart is offline  
Closed Thread


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 06:42 AM.


Powered by vBulletin® Version 3.8.0
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.