Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

How is the DB Insertion being done ?


leatherdealer

Recommended Posts

Hi guys and girls, enthusiasts,

I'd like to know how to insert data from a tep_input_field into the mysql database

 

I'm currently using the AJAX Attribute Manager Addon and added another input field to it for EAN/GTIN input. How can I submit the entered ean to my database ? 

See the Code and attached screenshot below

 

I've already added a column for ean and tried to add ean as input value. The Field is being shown, but inserting doesn't work.

Thanks for any help in advance. Have a nice day. 

<?php echo tep_draw_input_field("ean_$optionValueId",$optionValueInfo['ean'],' style="margin:3px 0px 3px 0px;" id="ean_'.$optionValueId.'" size="7" onfocus="amF(this)" onblur="amB(this)" onChange="return amUpdate(\''.$optionId.'\',\''.$optionValueId.'\',\'ean\');"'); ?>

 

variations.JPG

Link to comment
Share on other sites

On 1/23/2018 at 4:56 AM, leatherdealer said:

Hi guys and girls, enthusiasts,

I'd like to know how to insert data from a tep_input_field into the mysql database

 

I'm currently using the AJAX Attribute Manager Addon and added another input field to it for EAN/GTIN input. How can I submit the entered ean to my database ? 

See the Code and attached screenshot below

 

I've already added a column for ean and tried to add ean as input value. The Field is being shown, but inserting doesn't work.

Thanks for any help in advance. Have a nice day. 


<?php echo tep_draw_input_field("ean_$optionValueId",$optionValueInfo['ean'],' style="margin:3px 0px 3px 0px;" id="ean_'.$optionValueId.'" size="7" onfocus="amF(this)" onblur="amB(this)" onChange="return amUpdate(\''.$optionId.'\',\''.$optionValueId.'\',\'ean\');"'); ?>

 

variations.JPG

What happens when your product also has color option? How you gonna store the EAN? Also, I would look into the AM's source, I recall it uses AJAX to update the backend.

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...