Support Forums

Question about cities...

This is a discussion on Question about cities... within the Technical Support forums, part of the Technical Support Forums category; What version of 68 Classifieds are you running? Example: V4.1.6 Designer What template are you using? purple Please describe in ...


Go Back   68 Classifieds Forums > Technical Support Forums > Technical Support

Reply
 
Thread Tools Display Modes
Old 02-19-2010, 07:24 PM   #1
Customer
 
Join Date: Feb 2010
Location: Montreal, QC
Posts: 253
Rep Power: 11
EnergyFreak is on a distinguished road
Default Question about cities...

What version of 68 Classifieds are you running?
Example: V4.1.6 Designer

What template are you using?

purple
Please describe in detail the issue you are having:

Hi,

I have a question about cities. If a user for example writes in a city on his profile that does not make sense or with spelling errors. For example Montreal, montreal, montr�al, Montr�al, Montreeal, etc... I think all of these will become available on the search when searching by cities... I would like to avoid that, is there a way for the person to either choose from a list I give or a way to check for a valid address and make the necessary corrections.

Let me know what you think.
EnergyFreak is offline   Reply With Quote
Old 02-19-2010, 11:10 PM   #2
curmudgeon
 
Join Date: Mar 2006
Posts: 5,392
Rep Power: 135
Lhotch is a glorious beacon of light Lhotch is a glorious beacon of light Lhotch is a glorious beacon of light
Default

You could edit the template and change the test field to a dropdown list consisting of entries you put in to force them to chose.
__________________
Larry

Knowledge learned is more valuable than knowledge given.
Lhotch is offline   Reply With Quote
Old 02-21-2010, 06:16 PM   #3
Customer
 
Join Date: Feb 2010
Location: Montreal, QC
Posts: 253
Rep Power: 11
EnergyFreak is on a distinguished road
Default

How can I edit the user registration fields? I would replace an extra field with a list of cities, therefore I could just remove the check on the city field where the user can write his city with the new one. I read some documentation but none of it says I can modify the custom field to give it what I want, except give it a title.

Any ideas?
EnergyFreak is offline   Reply With Quote
Old 02-21-2010, 06:18 PM   #4
Customer
 
Join Date: Feb 2010
Location: Montreal, QC
Posts: 253
Rep Power: 11
EnergyFreak is on a distinguished road
Default

Quote:
Originally Posted by Lhotch
You could edit the template and change the test field to a dropdown list consisting of entries you put in to force them to chose.
Not sure what you mean about editing the template and change the test field. Can you give me more details on that?

Thanks.
EnergyFreak is offline   Reply With Quote
Old 02-21-2010, 09:56 PM   #5
curmudgeon
 
Join Date: Mar 2006
Posts: 5,392
Rep Power: 135
Lhotch is a glorious beacon of light Lhotch is a glorious beacon of light Lhotch is a glorious beacon of light
Default

Quote:
Originally Posted by EnergyFreak
Not sure what you mean about editing the template and change the test field. Can you give me more details on that?

Thanks.
I meant test field.

The template are HTML, the ciry field is a text field, edit the template and change it to a dropdown field and and manually create a dropdown for all the states you want to allow.
__________________
Larry

Knowledge learned is more valuable than knowledge given.
Lhotch is offline   Reply With Quote
Old 02-21-2010, 10:00 PM   #6
Customer
 
Join Date: Feb 2010
Location: Montreal, QC
Posts: 253
Rep Power: 11
EnergyFreak is on a distinguished road
Default

Quote:
Originally Posted by Lhotch
I meant test field.

The template are HTML, the ciry field is a text field, edit the template and change it to a dropdown field and and manually create a dropdown for all the states you want to allow.
Oh cool, would you happen to know which template piece has this? I have never coded a drop down before, how should I do that? Unless there is an example of that for the country in the template. I'll start looking for it right away.
EnergyFreak is offline   Reply With Quote
Old 02-21-2010, 10:27 PM   #7
curmudgeon
 
Join Date: Mar 2006
Posts: 5,392
Rep Power: 135
Lhotch is a glorious beacon of light Lhotch is a glorious beacon of light Lhotch is a glorious beacon of light
Default

look at the documentation link above the forum under common template changes and how to use the smarty debug console, it will allow you to see the templates in use on various pages.

As for making a dropdown, it basic html and the net is full of tutorials on all aspects of html/css.
__________________
Larry

Knowledge learned is more valuable than knowledge given.
Lhotch is offline   Reply With Quote
Old 02-23-2010, 08:20 PM   #8
Customer
 
Join Date: Feb 2010
Location: Montreal, QC
Posts: 253
Rep Power: 11
EnergyFreak is on a distinguished road
Default

I think I found what I need to change, it is located in /templates/default/user/userjoin.tpl.

I do not want to screw anything up, can someone tell me what piece of code I must add and what I need to change to build a drop down?

Here is the code:

PHP Code:
<class="{cycle values="row1,row2" advance=true}">
            <
label for="city">{if $req_city=="Y"}<span class='required'>{$smarty.const.LANG_STAR}</span>{/if}{$smarty.const.LANG_USER_CITY}{$smarty.const.LANG_COLON}</label>
            <
input {if $req_city=="Y"}class="required"{/if} name="city" type="text" id="city" value="{$city}" size="{$smarty.const.FIELD_SIZE}" />
        </
p
Thanks.

Last edited by EnergyFreak; 02-23-2010 at 08:31 PM.
EnergyFreak is offline   Reply With Quote
Old 02-23-2010, 08:35 PM   #9
Developer & Moderator
 
 
Join Date: Jan 2007
Location: Pennsylvania, USA
Posts: 2,238
Rep Power: 66
Mike-N-Tosh is just really nice Mike-N-Tosh is just really nice
Default

HTML select tag
__________________
Mike-N-Tosh
IndianaPC.org - A community website (v3.1.10 Developer - heavily modified & used as the CMS)
Sandbox [localhost(v3.1.10, v4.0.9, 4.1.10,4.2,5.0)] for development and customization
Visit My blog: reviews, tips, tricks, tutorials and my store with Templates, Mods & Docs
Web Hosting | Web Design & Development | 68 Classifieds Customizations
I am not a 68C employee, just a user and try to help out
Mike-N-Tosh is offline   Reply With Quote
Old 02-23-2010, 08:59 PM   #10
Customer
 
Join Date: Feb 2010
Location: Montreal, QC
Posts: 253
Rep Power: 11
EnergyFreak is on a distinguished road
Default

Okay so if I understand correctly I replace the <input> tags with the <select> tags you linked to?

If it's only that then I can manage
EnergyFreak is offline   Reply With Quote
Reply

Thread Tools
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
Import categories and cities Unregistered Pre Sales Questions 8 02-17-2010 04:55 PM
V4.1.x Registration - pre-filled cities mod jason1971 Modules / Plugins / Modifications 2 01-20-2010 12:28 AM
States/Cities and Search pipelin Technical Support 6 09-11-2009 01:01 PM
How to add cities damiun Technical Support 2 05-27-2009 08:15 AM
Cities and databases Zoozads Technical Support 13 03-07-2009 12:33 PM


All times are GMT -4. The time now is 11:44 AM.


Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2011, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0