News:

Bored?  Looking to kill some time?  Want to chat with other SMF users?  Join us in IRC chat or Discord

Main Menu

Make sure people read the registration agreement.

Started by Tristan Perry, October 31, 2004, 12:35:20 PM

Previous topic - Next topic

Tristan Perry

Quote from: rickc on December 15, 2004, 08:40:17 PM
Great, now I can add the part about owning their sole & it will all be legal ;D j/k

BTW I looked @ your forum & it didn't show the names, just the karma, its this because I wasn't logged in?
Your welcome  :) Also the thing about the karma: I didn't know that'd happen! I'll fix it when I can  :)

modtang

Blast from the past..... I know it's an old thread but this is a great code. I know no one reads my user agreement so I've just installed this. I'm using v1.0.5 and I needed to change the following:

<a href="'.dirname().'index.php?action=register">

to

<a href="/index.php?action=register">

If your board isn't installed in the root directory you need to account for that too (ie. add the path after the /).

Han

Sorry for kicking up this old topic but I like to implement this mod in my "SMF 1.1 RC 2" forum.
I adjusted the file "register.template.php". No problem there.

Now I want to adjust the file "register.php" and I'm looking for the line // No name?! How can you register with no name? but that line isn't there.

Where to put the code I have to add there?

Tristan Perry

No problem, try searching for the following instead:

Quote// Collect all extra registration fields someone might have filled in.

Thanks,
Tau Online

Han

Great it works  :D

Thank you very much Tau Online !!

Han

#25
I tested the mod and it works fine. Also the link to return to the registration-page works fine.
Just a little problem occured. My error logs shows this when the mod has done it's work.

2: Wrong parameter count for dirname()
Bestand: /home/....../public_html/forum/Sources/Register.php
Regel: 154


Han

#26
Problem solved  :)

This line in register.php created my problem :
Klik <a href="'.dirname().'index.php?action=register">hier</a> om opnieuw te registreren.',false);


I replaced it by this:
Klik <a href="http://www.pcnavigator.nl/forum/index.php?action=register">hier</a> om opnieuw te registreren.',false);


SeaOfSin

Quote from: Han on February 05, 2006, 01:13:53 PM
Problem solved  :)

This line in register.php created my problem :
Klik <a href="'.dirname().'index.php?action=register">hier</a> om opnieuw te registreren.',false);


.dirname should be $scripturl

Klik <a href="', $scripturl, '?action=register">hier</a> om opnieuw te registreren.',false);

Han


Tristan Perry

Ah thanks - I've never been 100% sure what variable to use. I've updated the first post to use $scripturl instead.

carpnick

// Collect all extra registration fields someone might have filled in.


I cannot find this line in Register.php inside the sources directory, am I missing something obvious?

Thanks,
Nick

Tristan Perry

Okay I've updated my first post so this will work with SMF 1.0.

bugsmi0

what a waste of tme reading registration agreement nothing but blah blah as if reading it will force you to follow the rules ha ha

Cottelletje

|| Leonardo Dicaprio is the Hottest Man Alive Believe Me ||

Cottelletje

people it now works but the link to go back to register doesn't work for me
i copied the register.php to the theme i use but that link doesn't work
'.$scripturl.'index.php?action=register this seems to be the link url is that right? :P
|| Leonardo Dicaprio is the Hottest Man Alive Believe Me ||

LuckyOne

#35
I really like the idea of 'forcing' new members to read the registration agreement, so I thought I'd give your tip/trick a go ... but now I've managed to screw up my registration process.

I'm fairly certain that I edited everything correctly, uploaded them to the proper places, etc., but when I did a test registration, I received the following error:

An Error Has Occurred!
You are not allowed to access this section 

Any help would be greatly appreciated.  (I'm using version 1.0.7.)  Thank you.

-LuckyOne

Tristan Perry

#36
Are you sure you followed the correct part - i.e. you searched for "// Trim any whitespace from the username." and not "// Collect all extra registration fields someone might have filled in."?

Sorry although I'm off on holiday in a matter of hours and so will be little help at the moment :-[

I can't really see where this would change things so that the registration cycle is broken.. I know this is old however I can remember testing it on 1.0(.4?) and it worked alright.

Actually, could you try changing the following:

In /Sources/Register.php
Find:

<br /><br />Please click <a href="', $scripturl, 'index.php?action=register">here</a> to re-register.',false);

Replace with:

<br /><br />Please click <a href="', $scripturl, '?action=register">here</a> to re-register.',false);

I think I messed the link back URL - it shouldn't have included the "index.php". If that doesn't work, I'd suggest just uninstalling this until I come back and can look into this further (I'll be back Saturday).

LuckyOne

Quote from: Tau Online on July 11, 2006, 05:22:12 AM
Actually, could you try changing the following:

In /Sources/Register.php
Find:

<br /><br />Please click <a href="', $scripturl, 'index.php?action=register">here</a> to re-register.',false);

Replace with:

<br /><br />Please click <a href="', $scripturl, '?action=register">here</a> to re-register.',false);

I think I messed the link back URL - it shouldn't have included the "index.php". If that doesn't work, I'd suggest just uninstalling this until I come back and can look into this further (I'll be back Saturday).

Thank you for the response!

Well, I did what you said and now we're a bit closer to the end result.  This time I get the following error:

An Error Has Occurred!

Congratulations! You just broken the Official World record for speed-reading!
Actually, we know you didn't read the forum rules, so please do so before continuing.

Please click <a href="


-LuckyOne

PrizeLive.com

Get Paid Instantly via PayPal (or other options) at PrizeLive.com!

eriktm


Advertisement: