Print Page | Close Window

Dropdown List of Countries

Printed From: ProductCart E-Commerce Solutions
Category: ProductCart
Forum Name: Customizing ProductCart
Forum Description: Exchange messages with other users that are customizing ProductCart.
URL: https://forum.productcart.com/forum_posts.asp?TID=2983
Printed Date: 11-March-2025 at 7:19am
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: Dropdown List of Countries
Posted By: theqc
Subject: Dropdown List of Countries
Date Posted: 26-August-2009 at 4:55pm
In the account setup and checkout page, there is a dropdown list of countries. Is there a quick way I can place US at the top of the list? Funny, I have performed so much major surgery on this cart, but something like this is throwing me off. Thanks in advance!



Replies:
Posted By: theqc
Date Posted: 27-August-2009 at 8:46am
Hello.

Just want to post an update that I got this working in case anybody ever needs to figure this out. All I did was create a new column in the "countries" database called "countryOrder" and gave the record "united state" a value of 1

and on the page includes/javascript/pcStateAndProvince.asp I change line 11 of the code. What I have bolded is what I added.

query="SELECT CountryCode,countryName,pcSubDivisionID, countryOrder FROM countries ORDER BY countryOrder DESC, countryName ASC"

Hope this can help someone out. Later



Posted By: sirene
Date Posted: 18-December-2009 at 5:30am
Where did you get the value set to 1?


Posted By: Hamish
Date Posted: 18-December-2009 at 6:55am
Hi Sirene,
   From theqc's post I take it that he added the additional database field and set it's value direct in the DB. (Edited for typo)


-------------
Editing ProductCart Code?

See http://wiki.earlyimpact.com/developers/editcode" rel="nofollow - WIKI Guidelines for Editing ProductCart's ASP Source Code



Posted By: sirene
Date Posted: 20-April-2010 at 4:44am
What is written in the SQL File?


CREATE TABLE [countries](
    [countryName] [nvarchar](255) NULL,
    [countryCode] [nvarchar](255) NULL,
    [countryOrder] [nvarchar](255) NULL,
    [pcSubDivisionID] [int] NULL CONSTRAINT [DBX_pcSubDivisionID_20378]  DEFAULT ((0))



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.04 - http://www.webwizforums.com
Copyright ©2001-2021 Web Wiz Ltd. - https://www.webwiz.net