Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Remote Linking To Off Site Mysql Servers


Recommended Posts

I am looking for a way to link to remote database servers and get basic information like stock items and quantities. I guess this is rather simple once you have login details arranged; this happens too when a new products page is opened in the browser but i am wanting to get the figures, descriptions, prices, quantities etc from many different suppliers and manipulate it to fit my site. With approvial ofcourse ;o)

 

matt

Link to comment
Share on other sites

well, I guess it may not be that simple. Here's just a quick question among others: would your host be happy to allow you to use their bandwidth to connect to a db server that is not within their network? For most osc shops, sites and db server are normally on the same machine or at least within the same internal network, and as such there would be no bandwidth issues. There may also be speed & reliability issues.

 

Ken

commercial support - unProtected channel, not to be confused with the forum with same name - open to everyone who need some professional help: either PM/email me, or go to my website (URL can be found in my profile).

over 20 years of computer programming experience.

Link to comment
Share on other sites

I dont think bandwidth will be too much of a problem as I expect to only run a remote lookup once a day and I have plenty of bandwidth to play with (100gb/month), yep i also know it is not unlimited...

 

anyway, just discovered a great technique to add new products to your remote website through your own home development server. Cpanel allows you to add ip addresses or host names who are allowed to acces your mysql server.

 

to get the login details etc goto your remote server's includes/configure.php file and find this... at the bottom.

 

// define('DB_SERVER', 'www.mysite.com' );

// define('DB_SERVER_USERNAME', 'myusername' );

// define('DB_SERVER_PASSWORD', 'mypassword' );

// define('DB_DATABASE', 'mydbname' );

 

and change the relative 'my_names' etc to what you need to access the remote mysql. easy ;o)

 

this way you can edit everything in your osc site (products, descriptions configuration etc) via your home development environment instead of uploading a new or backed up dbfile.sql.

 

ofcourse this only works for mysql, if suppliers are using msaccess pregreeesqlthingy, or others new unknowen_to_me coding is needed.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...