Customizing SMF > Now Available
Ask for gender during registration
kerux4:
Notice:
This tip has been in some way ported over to be a modification package located on the SMF modsite. Please note, the mod package may not do the exact same function and may not even use any of the code originally written for the tip, but should still hold the same basic functionality of the tip posted here. With the mod package for this tip, you can now let the SMF package manager make the code changes for you without you having to look at the code and edit it manually.
For documentation on using the SMF package manager, view this document.
To download the modification package, [please click here].
Is there a mod that makes people choose gender at registration? I have a couple of forums which one is for men and one for women.
[Unknown]:
You can do this the same way you do custom profile fields, using something like:
<input type="radio" name="gender" value="0" checked="checked" /> Leave it to the imagination<br />
<input type="radio" name="gender" value="1" /> Male<br />
<input type="radio" name="gender" value="2" /> Female<br />
In the Register template.
-[Unknown]
kerux4:
Where in there do I put this?
[Unknown]:
Where ever you want the option to appear :P.
For example, if you wanted it after the password, you'd find:
--- Code: --- </tr><tr>
<td width="40%">
<b>', $txt[82], ':</b>
</td>
<td>
<input type="password" name="passwrd2" size="30" />
</td>
</tr>
--- End code ---
Add after that:
--- Code: --- </tr><tr>
<td width="40%">
<b>Gender:</b>
</td>
<td>
<input type="radio" name="gender" value="0" checked="checked" /> Leave it to the imagination<br />
<input type="radio" name="gender" value="1" /> Male<br />
<input type="radio" name="gender" value="2" /> Female<br />
</td>
</tr>
--- End code ---
If you're not comfortable with HTML, I suggest you look at the tutorials on www.w3schools.com ;).
-[Unknown]
kerux4:
Alright, I have tried adding this several times and every time I save, it never takes.
Navigation
[0] Message Index
[#] Next page
Go to full version