Jump to content

Leecifer

Members
  • Content count

    6
  • Joined

  • Last visited

  1. Leecifer

    Custom Product Builder

    For anyone who had the same problem with the attribute sort order as me I've just found the resolution. In builder_add_attribute.php change tep_db_query("insert into " . TABLE_PRODUCTS_ATTRIBUTES . " values (NULL, '" . (int)$products_id . "', '" . (int)$options_id . "', '" . (int)$values_id . "', '" . tep_db_input($value_price) . "', '" . tep_db_input($price_prefix) . "')"); to tep_db_query("insert into " . TABLE_PRODUCTS_ATTRIBUTES . " values (NULL, '" . (int)$products_id . "', '" . (int)$options_id . "', '" . (int)$values_id . "', '" . tep_db_input($value_price) . "', '" . tep_db_input($price_prefix) . "', '" . (int)$products_options_sort_order . "', '" . (int)$sort_order . "', '" . (int)$attribute_sort . "', '" . (int)$options_values_weight . "')"); It just adds the write amount of columns to the database entry. Thankyou, ga'night, much love.
  2. Leecifer

    Custom Product Builder

    check the colums in your table and make sure the insert matches the number of columns and the postion. Hi bjfreeman, The error that I get shows that it is not adding enough columns so I realise that I need to put the code with the added "","","","" into the builder code somewhere, my problem is I don't know which PHP file controls how the columns are added to the database. I just need to find the insert code and then I can add the extra columns to be inserted. I hope this makes sense. Lee
  3. Leecifer

    Custom Product Builder

    Hi again, I had a go at fixing my issue regarding the attribute sort order contribution but I can't seem to get the 2 to work together. When I click to build my product the custom PC is added to the catalog but not the shopping cart and i get the error regarding database entry. I thought that the below code would need to be put into your code somewhere but I don't know where. insert into products_attributes values (NULL, '110', '28', '192', '0', '+', '', '', '', '') Any help would be great. Lee
  4. Leecifer

    Custom Product Builder

    1136 - Column count doesn't match value count at row 1 insert into products_attributes values (NULL, '110', '28', '192', '0', '+') [TEP STOP] I think I've figured out that the error above is because I'm using the attribute sort order contribution? This adds extra fields to the products_attributes table so when the builder tries to add the PC it is expecting there to only be 6 columns in the table whereas there are actually 10 due to the change made with sort order. Is there a way to change the insert to: insert into products_attributes values (NULL, '110', '28', '192', '0', '+', '', '', '', '') If so, in which php file would I need to do this? I may not even have this right as I'm not really a coding maestro but any help would be awesome. Thanks, Lee
  5. Leecifer

    Custom Product Builder

    I changed the default values back to NULL for catalog_products_id and it now allows me to choose from the components in the popup box but it still does not allow me to add or edit the builder categories. It also gives this error when I click build: 1136 - Column count doesn't match value count at row 1 insert into products_attributes values (NULL, '110', '28', '192', '0', '+') [TEP STOP] Regards, Lee
  6. Leecifer

    Custom Product Builder

    Hi, Great contribution, just can't get it working. I have the same problem as the previous poster being that I cannot add new categories or make changes to any of them. I received an error when updating to create the databases: 1067 - Invalid default value for 'catalog_products_id' ALTER TABLE products_options_values ADD COLUMN `catalog_products_id` int(11) NULL default 'NULL' [TEP STOP] Any idea what might be causing this? I've tried adding the fields myself but it doesn't fix the category problem. Cheers, Lee
×