Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

How to add 2 Custom Fields to Products?


jesse9201

Recommended Posts

Hello,

 

How do I add below each product description 2 new fields (one textfield for names, one textarea for message), so buyers can type in whatever they want AND I also receive these added fields as part of the order?

 

It's for a new personalized coffee mug site, which buyers can have their name and a short slogan/phrase screen printed on the cups.

 

Thanks.

Jess

 

P.S. I tried the "Add Extra Product Fields" contribution but it seems to only allow me offer customers to choose options (i.e. color/size) and doesn't allow the customer to type in whatever "they" want instead.

Link to comment
Share on other sites

You could copy part of the contact_us.php or checkout_confirmation.php files that use the text area fields as input for a new file. Create a couple of new fields under the orders_products_attributes in the dbase then when a customer adds something to the cart you update the order_products_attributes table with the new values of these fields if they are not empty. There is already code for the rest of the fields for the order_products_attributes table so it should be easy to do.

 

Finally when the email is sent to you, include the extra fields.

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...