Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Different products for different countries


nudylady

Recommended Posts

Posted

Where are no contribution, but I know how to do it. :)

Please read this line: Do you want to find all the answers to your questions? click here. As for contribution database it's located here!

8 people out of 10 don't bother to read installation manuals. I can recommend: if you can't read the installation manual, don't bother to install any contribution yourself.

Before installing contribution or editing/updating/deleting any files, do the full backup, it will save to you & everyone here on the forum time to fix your issues.

Any issues with oscommerce, I am here to help you.

Posted

I don't really know how to do it.

 

But I would hazard a fairly well educated guess at a simple query and SQL modification. I guess you'd have to specify where every product is available in the SQL tables, and modify the query that displays products to customer's to ensure the customer's country (entry_country_id field in address_book table) matches the country availability of the items to be displayed...

Obviously they'd have to be logged in for it to work, unless you went all out and used IP address tracing.

 

By the way great idea! I wish I had a use for it myself...

osCommerce is GREAT. When it works...

Posted
I don't really know how to do it.

 

But I would hazard a fairly well educated guess at a simple query and SQL modification. I guess you'd have to specify where every product is available in the SQL tables, and modify the query that displays products to customer's to ensure the customer's country (entry_country_id field in address_book table) matches the country availability of the items to be displayed...

Obviously they'd have to be logged in for it to work, unless you went all out and used IP address tracing.

 

By the way great idea! I wish I had a use for it myself...

 

Hide products by IP is too hard for me.

what about install 2 osc in 2 folders? USAcatalog and CANADAcatalog. USA IP goes USAcatalog. But I don't know how to do it!!!

Posted
Hide products by IP is too hard for me.

what about install 2 osc in 2 folders? USAcatalog and CANADAcatalog. USA IP goes USAcatalog. But I don't know how to do it!!!

 

Read this, it might help.

 

http://www.scripts.com/viewscript/redirect...y-country/7795/

 

Sounds like a good method of setting the default currency depending on location too! And the page that describes shipping prices...

osCommerce is GREAT. When it works...

Posted
Read this, it might help.

 

http://www.scripts.com/viewscript/redirect...y-country/7795/

 

Sounds like a good method of setting the default currency depending on location too! And the page that describes shipping prices...

 

 

that worked. now I can redirect to different index page by IP.

 

This code of redirect part

// If the visitors are from JP, redirect them to JP site 
if ($countrySHORT == "JP") 
{
 Header("Location: http://www.google.co.jp"); 
} else { 
// Otherwise, redirect them to US site 
 Header("Location: http://www.google.com");

 

If I want to add UK, CA. any one konws the simple code?

Posted
that worked. now I can redirect to different index page by IP.

 

This code of redirect part

// If the visitors are from JP, redirect them to JP site 
if ($countrySHORT == "JP") 
{
 Header("Location: http://www.google.co.jp"); 
} else { 
// Otherwise, redirect them to US site 
 Header("Location: http://www.google.com");

 

If I want to add UK, CA. any one konws the simple code?

 

 

You'll have to lookup the IP address ranges. But there's also the problem of different IP classes.

http://www.maxmind.com/app/geoip_country

That is a link to a free IP address database, but the free ones aren't great as they identify any AOL users as US locations regardless of their real location.

If you can figure out the AOL IP addresses maybe you can modify it yourself.

 

Also, if you're going to have a lot of different redirects, I'd recommend putting the redirect address in the database, and then your php script can just say to redirect to database_redirect field.

osCommerce is GREAT. When it works...

Posted
solved matter solved. use

 

if {}

else if

{}

else{ }

One thing that bothers me about using ip addresses is this. A customer in one country ships to another country. The country that the "product" is shipped to is, for reasons of trade agreements or whatever, not permitted to receive the "product". Now that is not a problem unless you have other "products" that you can sell to the second country.

Posted
One thing that bothers me about using ip addresses is this. A customer in one country ships to another country. The country that the "product" is shipped to is, for reasons of trade agreements or whatever, not permitted to receive the "product". Now that is not a problem unless you have other "products" that you can sell to the second country.

 

That's a good point. I guess you'd need to check shipping address country and IP country match. Would be a pain in the arse for a few customers. Or display all products but highlight some as only being available for shipping to abc country.

 

I plan on using the ip addresses to switch currencies for customers automatically, and to have the countries on registration and shipping pages already selected to their country (but can be changed). I looked for a contribution that might do this and there doesn't seem to be one. Do you know of one? If not, I'll upload it when/if I get it to work.

osCommerce is GREAT. When it works...

Posted
I wish tracking by IP address.

 

Web-project: how much you charge for this.

 

see private message.

Please read this line: Do you want to find all the answers to your questions? click here. As for contribution database it's located here!

8 people out of 10 don't bother to read installation manuals. I can recommend: if you can't read the installation manual, don't bother to install any contribution yourself.

Before installing contribution or editing/updating/deleting any files, do the full backup, it will save to you & everyone here on the forum time to fix your issues.

Any issues with oscommerce, I am here to help you.

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...