View Full Version : default country for create account
computerwiz5
12-27-04, 12:47 AM
I thought it would be appropriate to address this question here
Stevel, I saw your modification for the country state selector, I installed it, a long time ago though. Btu now I decided I do not want anyone signing up if they aren’t form the US. How and what do I have to hardcode so all occurrences, like in the create account, address book, etc will have the US id hard coded in there? Is there a contribution.
Thanks
Danny
Well, it probably would have been better to ask in the support thread for Country-State Selector at the osCommerce forum. But anyway...
In the forms you are interested, delete this:
<tr>
<td class="main"><?php echo ENTRY_COUNTRY; ?></td>
<?php // +Country-State Selector ?>
<td class="main"><?php echo tep_get_country_list('country',$country,'onChange= "return refresh_form(create_account);"') . ' ' . (tep_not_null(ENTRY_COUNTRY_TEXT) ? '<span class="inputRequirement">' . ENTRY_COUNTRY_TEXT . '</span>': ''); ?></td>
<?php // -Country-State Selector ?>
</tr>
That should do it.
computerwiz5
12-27-04, 09:25 PM
What page do i have to do this too, the create account page, and address book page or what? I do not want them to create a account if there are not in the us, or i do not want them to ship outside the US. I dont want want anything to to with the remainign counties. Only US. What pages would i edit?
Thanks Stevel
what do you have against us Canadians? hehe
My Country-State Selector contribution has edits to a number of files. But you don't need that if you simply want to restrict usage to US, as the contribution has not much value for a single country.
Do these two things. First, open your database using phpmyadmin.powweb.com and select the SQL tab. Type the following in and click GO:
DELETE FROM countries WHERE countries_name != 'United States';
This post (http://forums.oscommerce.com/index.php?showtopic=113815&view=findpost&p=453419) shows how to get the state drop down to appear by default.
vBulletin v3.6.0, Copyright ©2000-2009, Jelsoft Enterprises Ltd.