PDA

View Full Version : Integration with current database


tjcook
December 9th, 2003, 06:36 PM
Hello, I'm developing for a music publishing company. Their site will require several tables separate from the shopping cart.

Also, I would like to add more fields such as 'url_to_pdf' , 'composer', 'length', etc. for each catalogue item. I've seen in http://www.ldev.com/forums/showthread.php?t=1015 that you say: "All the data for the 12 text options would end up stored in a single MySQL table field, using the serialize command to turn the array into storable data. For this reason, a MySQL export alone would not give you the option info in a readable format."

I wouldn't want to mess with the serialize command. It seems like there should be support for this. I've seen that in www.madaboutfood.net they have a field that allows the buyer to insert a message for a gift card. I assume such a thing would be a new field in the order?

Please explain how this works. I'm very excited about the shopping cart and hope it can do everything we need to do.

Jamie
December 10th, 2003, 01:36 PM
Hi,

We do not have support for adding additional product fields. The gift card field you saw was actually a text product option designed to collect data from the customer.

If you are familiar with phpMyAdmin, you could add fields to your products table, and they would show up in the admin section of the cart. You could also add them to the product templates to make that data show up, like so:

URL to PDF: <?=$URL_to_PDF?>

The variable name would need to match the name of the field in the database.

This could cause problems should you decide to upgrade, however. We also wouldn't be able to provide support for that, as it is beyond the capability of the cart.

We will be adding a feature in the future to allow you to add custom fields through the cart itself, but do not have an ETA for it.

Thanks,
Jamie

tjcook
December 10th, 2003, 05:10 PM
Many thanks, Jamie.

So I'll have to have a separate table referencing the product_id in the cart's structure? Is that right? Because that's fine by me.

Then, in queries I'd just have to select both the tables SELECT products = shoppingcart where product_id = $product_id, or something to that effect. Yah? All I want to be able to do is bring more info to the table than what the shopping cart provides automatically.

-t.j.

Hi,

We do not have support for adding additional product fields. The gift card field you saw was actually a text product option designed to collect data from the customer.

If you are familiar with phpMyAdmin, you could add fields to your products table, and they would show up in the admin section of the cart. You could also add them to the product templates to make that data show up, like so:

URL to PDF: <?=$URL_to_PDF?>

The variable name would need to match the name of the field in the database.

This could cause problems should you decide to upgrade, however. We also wouldn't be able to provide support for that, as it is beyond the capability of the cart.

We will be adding a feature in the future to allow you to add custom fields through the cart itself, but do not have an ETA for it.

Thanks,
Jamie

Jamie
December 11th, 2003, 06:11 AM
Hi T.J.,

Actually, you can do it all within the same Products table. If you do it that way, you won't need to add any code to grab the info. All you would need to do is to add the field name to the show_product_detail.php template.

Thanks,
Jamie