Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Missing data in product edit


Didgemandu

Recommended Posts

Hi all,

 

I am in awe of this contribution. its exactly, to the letter, what I wanted!

 

However, I do have a problem - when editing a product the products_price and vendors_prod_id are coming up blank even if I have inserted the information before, and it displays! Very strange! Can anyone help?

 

Oh and to clarify, if I update the product it is overwriting blank information to the database - hence meaning having to enter the product price every time I edit the product details - something which at this early stage in the game I am finding I am doing a fair bit!

 

I think its going to be something simple - like the order the variables are specified in: (code from the MVS install package)

 

    //MVS start   Many additions here, the order they are listed is very important, all new fields have vendor or vendors in the name (ie, "p.vendors_product_price,")
   if (isset($HTTP_GET_VARS['pID']) && empty($HTTP_POST_VARS)) {
     $product_query = tep_db_query("select pd.products_name, pd.products_description, pd.products_url, p.products_id, p.products_quantity, p.products_model, p.vendors_prod_id, p.products_image, p.products_price, p.vendors_product_price, p.products_weight, p.vendors_prod_comments, p.products_date_added, p.products_last_modified, date_format(p.products_date_available, '%Y-%m-%d') as products_date_available, p.products_status, p.products_tax_class_id, p.vendors_id, p.manufacturers_id from " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd where p.products_id = '" . (int)$HTTP_GET_VARS['pID'] . "' and p.products_id = pd.products_id and pd.language_id = '" . (int)$languages_id . "'");
     $product = tep_db_fetch_array($product_query);
 //MVS end

 

I have the header tags seo contribution installed also - this is my current version of this line:

 

    //MVS start   Many additions here, the order they are listed is very important, all new fields have vendor or vendors in the name (ie, "p.vendors_product_price,")
  /*** Begin Header Tags SEO ***/
  if (isset ($HTTP_GET_VARS['pID']) && (!$HTTP_POST_VARS) ) {
     $product_query = tep_db_query("select pd.products_name, pd.products_description, pd.products_head_title_tag, pd.products_head_desc_tag, pd.products_head_keywords_tag, pd.products_url, p.products_id, p.products_quantity, p.products_model, p.products_image, p.vendors_product_price, p.products_weight, p.vendors_prod_comments, p.products_date_added, p.products_last_modified, date_format(p.products_date_available, '%Y-%m-%d') as products_date_available, p.products_status, p.products_tax_class_id, p.vendors_id, p.manufacturers_id from " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd where p.products_id = '" . (int)$HTTP_GET_VARS['pID'] . "' and p.products_id = pd.products_id and pd.language_id = '" . (int)$languages_id . "'");
     $product = tep_db_fetch_array($product_query);                            
  /*** End Header Tags SEO ***/
 //MVS end

 

Hope somebody can help!

 

Cheers

 

Didgemandu

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.

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...