Page 1 of 1

Using Access DB to Update Website Prices

Posted: Mon Jan 11, 2010 2:43 pm
by AquaRogg
I am fairly new to the php world but have been using basics for some time now, and have dabbled a little in databases. That being said I am hoping someone can help.

I am creating a website that has items customers can purchase, cart manager is the program I use to collect the information, which is then retrieved from a secure server and manually processed.

What I am hoping to do is create a MS Access Database with all my part numbers and prices in the following format

Database File-Table:Category-Item Number & Price

I would like my website to access the DB file and pull the current pricing from it, then display that price in the proper location as well as inserting it into the code for cart manager.

For reference the cart manager code is in the following format:

Code: Select all

 
<form method=POST action="https://www.cartmanager.net/cgi-bin/cart.cgi">
     <input type=hidden name=additem value="cartid|itemname|itemcost|itemquantity
               |itemno|itemhandling|itemshipmethod|itemweight|itemexempt|itemdiscount
               |itemsilentpost|itemdropshipzip|itemESD|itemRecurring">
     <input type=submit value="Add To Cart">
</form> 
 


The itemcost is the only part that needs to be dynamically changed, though if the implementation of this is fairly simple I may extend it to the description as well.

Then if pricing ever changed a simple change in the database would be reflected wherever the instance occurred on the site.

Thank you for any help you can provide!

Re: Using Access DB to Update Website Prices

Posted: Mon Jan 11, 2010 3:17 pm
by Christopher
I think you can use the ODBC database library for MS Access databases. See the PHP manual for examples.

I am not sure about you hosting, but you may want to consider using a relational database server rather than Access. One is usually provided with hosting plans.

Re: Using Access DB to Update Website Prices

Posted: Mon Jan 11, 2010 4:21 pm
by AquaRogg
My hosting is Network Solutions, a quick check shows it uses Ruby Rails.

My head is reeling with the search results I have come up with trying to do this. If anyone has some links to some information that will help step me through:

1. Setting up the database (one compatible with Ruby Rails and able to do what I mentioned)
2. Setting up the database on the server (I have no clue what a relational database is :oops:
3. php code relating to what I need to do

I am a quick learner and would like to learn how to do this, just need someone that can point me in the right direction. As I said, I know what I want to do, but search engines just confused me!

Thanks!