Jump to content


- - - - -

IP.Board 2.3: Make "location" field required at registration for 2.3.5


  • Please log in to reply
10 replies to this topic

#1 smallblockfuelie

smallblockfuelie

    Post Guru

  • IM Supporters
  • PipPipPipPipPipPipPipPip
  • 1,261 posts
  • Location:NW Missouri
  • Real Name:Heath
  • IPB Version:v3.2.x
Contributor

Posted 01 May 2008 - 11:04 PM

This is the support topic for the tutorial Make "location" field required at registration for 2.3.5.  Please post here if you have any questions or feedback.

#2 RichardC

RichardC

    ^^ They think you are odd

  • IM Supporters
  • PipPipPipPipPipPipPipPip
  • 1,028 posts
  • Location:United Kingdom
  • Real Name:Richard
  • IPB Version:v2.3.x
Contributor

Posted 02 May 2008 - 08:05 AM

Is there any way within this mod that you can make the Location field a drop down box?

To avoid people putting in 'random' stuff like 'at home' or 'under your bed' etc, we are currently using a 2nd custom field which we require at registration. Obviously this currently creates 2 location fields.

example data (tailored for my forum)

=
Bedfordshire=Bedfordshire
Berkshire=Berkshire
Buckinghamshire=Buckinghamshire
Cambridgeshire=Cambridgeshire
Cheshire=Cheshire
Cleveland=Cleveland
Cornwall=Cornwall
Cumbria=Cumbria
Derbyshire=Derbyshire
Devon=Devon
Dorset=Dorset
Durham=Durham
Essex=Essex
Gloucestershire=Gloucestershire
GreaterLondon=Greater London
GreaterManchester=Greater Manchester
Hampshire=Hampshire
HerefordandWorcester=Hereford and Worcester
Hertfordshire=Hertfordshire
Humberside=Humberside
Kent=Kent
Lancashire=Lancashire
Leicestershire=Leicestershire
Lincolnshire=Lincolnshire
Merseyside=Merseyside
Norfolk=Norfolk
Northamptonshire=Northamptonshire
Northumberland=Northumberland
Nottinghamshire=Nottinghamshire
Oxfordshire=Oxfordshire
Rutland=Rutland
Shropshire=Shropshire
Somerset and Avon=Somerset and Avon
Staffordshire=Staffordshire
Suffolk=Suffolk
Surrey=Surrey
Sussex=Sussex
Tyne&Wear=Tyne & Wear
Warwickshire=Warwickshire
WestMidlands=West Midlands
Wiltshire=Wiltshire
Yorkshire=Yorkshire
NorthernIreland=Northern Ireland
SouthernIreland=Southern Ireland
IsleofMan=Isle of Man
IsleofWight=Isle of Wight
Scotland=Scotland
Wales=Wales
Europe=Europe
RestofWorld=Rest of World

regards,

Richard

#3 RichardC

RichardC

    ^^ They think you are odd

  • IM Supporters
  • PipPipPipPipPipPipPipPip
  • 1,028 posts
  • Location:United Kingdom
  • Real Name:Richard
  • IPB Version:v2.3.x
Contributor

Posted 06 May 2008 - 09:39 AM

bump ;)

#4 AmgedOsman

AmgedOsman

    aka Sacred

  • IM Supporters
  • PipPipPipPipPipPipPipPipPip
  • 2,027 posts
  • Location:Egypt - Cairo
  • Real Name:amGed
  • IPB Version:v3.3.x
Contributor

Posted 21 May 2008 - 01:57 PM

Find:

<fieldset class="row3">
					<legend><b>Location</b></legend>
						<table class='ipbtable' cellspacing="0">
							<tr>
								<td nowrap="nowrap">Enter your location:</td>
							</tr>
							<tr>
								<td><input type="text" size="50" name="Location" /></td>
							</tr>
						</table>
					</fieldset>
Replace with

<fieldset class="row3">
					<legend><b>Location</b></legend>
						<table class='ipbtable' cellspacing="0">
							<tr>
								<td nowrap="nowrap">Enter your location:</td>
							</tr>
							<tr>
 		<td class="row2"><select name="location" value="{$this->ipsclass->member['location']}" class='forminput'>
					<option selected="selected" value="{$this->ipsclass->member['location']}" style="font-family:{$this->ipsclass->member['location']}">{$this->ipsclass->member['location']}</option>
					<option value="">Default</option>
					<option value="Egypt">Egypt</option>
					<option value="usa">USA</option>
					<option value="france">France</option>
					</select></td>
							</tr>
						</table>
					</fieldset>

i didnt try it but it should work
let me know teh results

also make sure to add more countries
Facebook Senior Account Manager (MENA Region)
MSN Senior Account Manager (MENA Region)

Posted Image
@amgedosman | AmgedOsman.com

#5 RichardC

RichardC

    ^^ They think you are odd

  • IM Supporters
  • PipPipPipPipPipPipPipPip
  • 1,028 posts
  • Location:United Kingdom
  • Real Name:Richard
  • IPB Version:v2.3.x
Contributor

Posted 21 May 2008 - 02:04 PM

oooh, thanks amGed, I will try this when I get home tonight ;)

Richard

#6 AmgedOsman

AmgedOsman

    aka Sacred

  • IM Supporters
  • PipPipPipPipPipPipPipPipPip
  • 2,027 posts
  • Location:Egypt - Cairo
  • Real Name:amGed
  • IPB Version:v3.3.x
Contributor

Posted 21 May 2008 - 02:09 PM

NP Richard, Just please let me know the results :) .
Oh and if it worked u will probably add  more countries please post them here iam sure they could be useful to many people ;)
ty.

Edited by Sacred, 21 May 2008 - 02:13 PM.

Facebook Senior Account Manager (MENA Region)
MSN Senior Account Manager (MENA Region)

Posted Image
@amgedosman | AmgedOsman.com

#7 RichardC

RichardC

    ^^ They think you are odd

  • IM Supporters
  • PipPipPipPipPipPipPipPip
  • 1,028 posts
  • Location:United Kingdom
  • Real Name:Richard
  • IPB Version:v2.3.x
Contributor

Posted 21 May 2008 - 02:35 PM

we use mainly UK counties + Europe/rest of world, (scroll up) but I will post a list should anyone want them.

#8 AmgedOsman

AmgedOsman

    aka Sacred

  • IM Supporters
  • PipPipPipPipPipPipPipPipPip
  • 2,027 posts
  • Location:Egypt - Cairo
  • Real Name:amGed
  • IPB Version:v3.3.x
Contributor

Posted 22 May 2008 - 09:17 AM

okay thanks but umm did it work ;) ?
Facebook Senior Account Manager (MENA Region)
MSN Senior Account Manager (MENA Region)

Posted Image
@amgedosman | AmgedOsman.com

#9 RichardC

RichardC

    ^^ They think you are odd

  • IM Supporters
  • PipPipPipPipPipPipPipPip
  • 1,028 posts
  • Location:United Kingdom
  • Real Name:Richard
  • IPB Version:v2.3.x
Contributor

Posted 22 May 2008 - 09:20 AM

no idea, Man U vs Chelsea took priority ;) - ill check tonight

#10 AmgedOsman

AmgedOsman

    aka Sacred

  • IM Supporters
  • PipPipPipPipPipPipPipPipPip
  • 2,027 posts
  • Location:Egypt - Cairo
  • Real Name:amGed
  • IPB Version:v3.3.x
Contributor

Posted 22 May 2008 - 09:21 AM

haha yeah same here
Facebook Senior Account Manager (MENA Region)
MSN Senior Account Manager (MENA Region)

Posted Image
@amgedosman | AmgedOsman.com

#11 RocketFoot

RocketFoot

    Will I ever understand this stuff?

  • IM Supporters
  • PipPipPipPipPipPipPip
  • 656 posts
  • Location:Latrobe, PA
  • Real Name:Barry
  • IPB Version:v3.1.x
Contributor

Posted 16 March 2009 - 01:02 PM

Is there an update to this for 2.3.6?  The 2nd edit to sources/action_public/register.php doesn't match what I have in my actual file??
My Forum:
www.BigMackTrucks.com
IPB v3.1.2 with Gallery, Blog & DevFuse Garage Module




1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users