News:

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

Main Menu

Gender On Registration

Started by JayBachatero, August 01, 2006, 11:51:17 PM

Previous topic - Next topic

JayBachatero

Link to Mod

This was originally posted to Tips & Tricks by [Unknown] - packaged as a mod by JayBachatero

http://www.simplemachines.org/community/index.php?topic=27772.0
Follow me on Twitter

"HELP!!! I've fallen and I can't get up"
This moment has been brought to you by LifeAlert

denislici


would he/she be forced to choose ?
Love the Creature for Creator's sake. (English)
Duje Krijesen per hire te Krijuesit. (Albanian)
Yaradılan'ı sev Yaradan'dan ötürü. (Turkish)
Ami la Creatura per ce la creato il Creatore. (Italian)

JayBachatero

No but you can make it be required.
Follow me on Twitter

"HELP!!! I've fallen and I can't get up"
This moment has been brought to you by LifeAlert

fasterthanyours

Can you make a mod or is there a mod for requiring Location?

JayBachatero

There is a Tip & Tricks about it I believe.  I know it was asked for many many times before..
Follow me on Twitter

"HELP!!! I've fallen and I can't get up"
This moment has been brought to you by LifeAlert

desistyle

will this work for smf 1.1 rc3

JayBachatero

Follow me on Twitter

"HELP!!! I've fallen and I can't get up"
This moment has been brought to you by LifeAlert

desistyle

An Error Has Occurred!
The package you tried to upload either is not a valid package or has become corrupted. :-[

JayBachatero

Follow me on Twitter

"HELP!!! I've fallen and I can't get up"
This moment has been brought to you by LifeAlert

desistyle

did it w/o a problem thanks

Installations actions for "Gender On Registration":
Installing this package will perform the following actions:
   Type    Action    Description
1.    Execute Modification    ./Themes/default/Register.template.php    Test successful

Gobo

#10
Quote from: denislici on August 02, 2006, 07:10:54 AM

would he/she be forced to choose ?
Quote from: JayBachatero on August 02, 2006, 12:16:50 PM
No but you can make it be required.

could you tell me how?

Aku


JayBachatero

In Register.template.php Find and remove

<input type="radio" name="gender" value="0" checked="checked" tabindex="', $context['tabindex']++, '" /> ', $txt[470], '<br />
Follow me on Twitter

"HELP!!! I've fallen and I can't get up"
This moment has been brought to you by LifeAlert

dustydogge

Quote from: JayBachatero on November 11, 2006, 12:23:46 AM
In Register.template.php Find and remove

<input type="radio" name="gender" value="0" checked="checked" tabindex="', $context['tabindex']++, '" /> ', $txt[470], '<br />


Yes but that just removes the "N/A" option from the 3 options, leaving just "male" and "female" to be chosen. But with this code, if you choose neither the registration still goes ahead. What I mean was, can it be changed so that if the applicant doesn't make a choice out of the two, the registration does not complete? A popup giving an error and directing the applicant to choose one of them would be perfect.

JayBachatero

True.  It was just a quick fix.  You can make it that "female" is picked by default and that would make them change it ;).  I'll see what I can do about making it mandatory.
Follow me on Twitter

"HELP!!! I've fallen and I can't get up"
This moment has been brought to you by LifeAlert

dustydogge

Hehe sure, thanks but I'd still prefer if they HAD to make a choice themselves. Sometimes, guys would pretend to be girls on the forum and I don't wanna help them out by pre-selecting "female" as the gender.

Please do let me know if you come up with something. Thanks.

JayBachatero

Ok I haven't tried this so not sure if it's going to work.  In Subs-Member.php
Code (find) Select

// Setup the activation status on this new account so it is correct - firstly is it an under age account?
if ($regOptions['require'] == 'coppa')


Code (add before) Select

// Make them pick a gender.
if (empty($regOptions['extra_register_vars']['gender']))
fatal_error('Please select a gender');
Follow me on Twitter

"HELP!!! I've fallen and I can't get up"
This moment has been brought to you by LifeAlert

dustydogge

I assume that the Subs-Member.php you are talking about would be located in the Sourcesnew folder, since I upgraded to RC3.

After modifying it, there is no change....the registration still proceeds. No fatal errors.

JayBachatero

Yes that's the correct file.  I'll look into it tom and post something.
Follow me on Twitter

"HELP!!! I've fallen and I can't get up"
This moment has been brought to you by LifeAlert

rockinaway

Have I helped you? Then please join AdminFuel - The forum for forum administrators.

If you need help managing your forum, or maybe launching it, then visit us and view the quality articles, downloads and posts.

JayBachatero

Follow me on Twitter

"HELP!!! I've fallen and I can't get up"
This moment has been brought to you by LifeAlert

rockinaway

Have I helped you? Then please join AdminFuel - The forum for forum administrators.

If you need help managing your forum, or maybe launching it, then visit us and view the quality articles, downloads and posts.

internetbrother

I can't upload it into my packagemanage it says

The package you tried to upload either is not a valid package or has become corrupted.

JayBachatero

What version of SMF are you using?
Follow me on Twitter

"HELP!!! I've fallen and I can't get up"
This moment has been brought to you by LifeAlert

Xcat


djpaddystudio7

it is not compatible with 1.1.2 ...
i thought of doing the thing manually but the coding is diffrent from earlier versions . couldnt apply the mod the way it could be done in earlier versions.

anyways if someone suggests a modification for adding this thing then plz do tell me what i need to modify to get this too http://www.simplemachines.org/community/index.php?topic=134713.0


JayBachatero

Quote from: Xcat on March 20, 2007, 05:04:12 AM
Compatible with 1.1.2?
Just tested it and it works on 1.1.2.
Follow me on Twitter

"HELP!!! I've fallen and I can't get up"
This moment has been brought to you by LifeAlert

RiderRaghav

I tried installing it on 1.1.3v and it gave me these errors :( ....

QuoteInstalling this package will perform the following actions:
   Type    Action    Description
1.    Execute Modification    ./Themes/default/Register.template.php    Test failed

TrueSatan

All that has happened is that another mod you have previously installed has altered the file that you have a fail on...this mod has found that the file is different from what it is set to edit. The resolution for all such fails is to do a manual installation of the mod.

http://docs.simplemachines.org/index.php?topic=402.msg531#msg531

RiderRaghav

Quote from: TrueSatan on July 07, 2007, 08:01:14 PM
All that has happened is that another mod you have previously installed has altered the file that you have a fail on...this mod has found that the file is different from what it is set to edit. The resolution for all such fails is to do a manual installation of the mod.

http://docs.simplemachines.org/index.php?topic=402.msg531#msg531

I tried to install it manually but still I'm getting the same error :( .... What should I do ???

Any help would be appreciated ......

TrueSatan

The error you reported was a fail in the package manager so I don't see how you can have the same error if you are trying a manual installation...please follow the instructions in the link I gave you previously.

LadyC

any chance you could add little gender icons that would appear under a person's name when they post a message?

TrueSatan

@ LadyC

Such an function is not part of this mod.

LadyC

maybe someone will write such a mod one day soon.... i hope!

JayBachatero

Quote from: LadyC on August 30, 2007, 12:55:11 PM
any chance you could add little gender icons that would appear under a person's name when they post a message?
Admin > Current Theme > Show gender images in message view
Follow me on Twitter

"HELP!!! I've fallen and I can't get up"
This moment has been brought to you by LifeAlert

LadyC


Jade Elizabeth

is there any way to make it so that they MUST chose between male and female?
lol i saw some reference to it earlier in the thread, but i think its for an earlier version?
Once proud Documentation Writer and Help Squad Leader | Check out my new adult coloring career: Color With Jade/Patreon.

TrueSatan


JayBachatero

Quote from: Alundra on September 20, 2007, 11:54:23 AM
is there any way to make it so that they MUST chose between male and female?
lol i saw some reference to it earlier in the thread, but i think its for an earlier version?

Quote from: JayBachatero on November 11, 2006, 12:23:46 AM
In Register.template.php Find and remove

<input type="radio" name="gender" value="0" checked="checked" tabindex="', $context['tabindex']++, '" /> ', $txt[470], '<br />

Follow me on Twitter

"HELP!!! I've fallen and I can't get up"
This moment has been brought to you by LifeAlert

TrueSatan


Jade Elizabeth

awesome!! thankyou!!

can i do the same to get it out of the profile settings?
*goes off to find file with that line in it*
Once proud Documentation Writer and Help Squad Leader | Check out my new adult coloring career: Color With Jade/Patreon.

cru


Jade Elizabeth

Once proud Documentation Writer and Help Squad Leader | Check out my new adult coloring career: Color With Jade/Patreon.

falguni1


TrueSatan

Please read the postings in the topic...the mod already works with SMF 1.1.4!

MoreBloodWine

I know this is insanely old andn ot supported any more but does anyone want to maybe take this up and mod it for 2.0 ?
Want a sig like mine for your BTCGuild stats ? Then check this out: Spend-ur-Bits


Advertisement: