ivan20012 Posted November 20, 2010 Share Posted November 20, 2010 Hello -- I have 7 products, each of which has 46 color possibilities and 10 sizes. I loaded all of the combinations, assigned individual reference numbers, and the products all worked fine in the front office. However, I later made some modifications to a couple of the products, adding in colors that I had inadvertently omitted. Now, one of those products no longer works. It only allows you to add the default product at the default price to the cart. I opened the site in Internet explorer and I found the following errors: Webpage error details Message: Unterminated string constant Line: 306 Char: 75 Code: 0 URI: http://127.0.0.1/prestashop/product.php?id_product=116 Message: Object doesn't support this property or method Line: 83 Char: 4 Code: 0 URI: http://127.0.0.1/prestashop/product.php?id_product=116 Message: 'id_color_default' is undefined Line: 106 Char: 2 Code: 0 URI: http://127.0.0.1/prestashop/themes/moon/js/product.js I've noticed that even the products that work have an error code: Webpage error details Message: Object doesn't support this property or method Line: 83 Char: 4 Code: 0 URI: http://127.0.0.1/prestashop/product.php?id_product=112 I'm working with the latest version of Prestashop and the moon theme. I tried clicking "v1.1 theme compatibility" in preferences, but that didn't help. Could anyone let me know how to fix this? Thanks so much in advance. Link to comment Share on other sites More sharing options...
tomerg3 Posted November 20, 2010 Share Posted November 20, 2010 Can you check the error log in Firefox? Link to comment Share on other sites More sharing options...
ivan20012 Posted November 21, 2010 Author Share Posted November 21, 2010 Even though the product also does not work in firefox, firefox does not give me any error message. I am only able to see error messages in internet explorer. As I mentioned, all of the other products work fine (in both internet explorer and firefox). The other products have the same number of attributes/price changes depending on the combination chosen as the "broken" product, but for this one broken product, only the default combination can be added to the cart. Based on the internet explorer message, I am assuming that there is a javascript error, but I don't know to address it. Link to comment Share on other sites More sharing options...
tomerg3 Posted November 21, 2010 Share Posted November 21, 2010 try to duplicate the item, and see if the new one works. Link to comment Share on other sites More sharing options...
ivan20012 Posted November 21, 2010 Author Share Posted November 21, 2010 Thanks for the suggestion -- it shows me that at least I'm thinking the right way. Before I post, I try lots of things on my own, so that I won't waste people's time too much. Before posting, I duplicated the broken product, but the duplicated product also did not work. I also wondered whether my database was just too large, so I duplicated one of the other products to see if that duplication worked. That duplicated product worked perfectly, which led me to believe that the problem is not that the database is too large. That's what led me to compare the working products with the broken product in internet explorer. The only difference between the broken product and the working product is the error code Message: 'id_color_default' is undefined Line: 106 Char: 2 Code: 0 URI: http://127.0.0.1/prestashop/themes/moon/js/product.js That said, I don't understand how a javascript error could affect only one product. Shouldn't it affect all of the products? Link to comment Share on other sites More sharing options...
tomerg3 Posted November 22, 2010 Share Posted November 22, 2010 It sounds like you deleted the default color attribute, you may want to set that again. Link to comment Share on other sites More sharing options...
ivan20012 Posted November 22, 2010 Author Share Posted November 22, 2010 How do I re-set the default color attribute? Also, I'm doing my best to learn prestashop -- coul you also explain how accidentally deleting or changing the default color attribute could only break one product? Thanks again for your help. Link to comment Share on other sites More sharing options...
tomerg3 Posted November 25, 2010 Share Posted November 25, 2010 I'm pretty sure it's related to the color picker.Try using the Color attribute management, which should set the default color id (which is currently missing) Link to comment Share on other sites More sharing options...
ivan20012 Posted November 27, 2010 Author Share Posted November 27, 2010 Try using the Color attribute management, which should set the default color id (which is currently missing) I'm sorry, but I don't understand. At the bottom of the combinations page, there is "color attribute management." If I click on that, it gives the message "are you sure you want to delete entered product information?" If I click okay, it takes me to attributes and groups section of the back office. Colors is listed among the attributes, and "this is a color group" is checked. What exact steps should I follow to set the default color id? Link to comment Share on other sites More sharing options...
ivan20012 Posted November 30, 2010 Author Share Posted November 30, 2010 Hi -- I think I figured out a solution (though, it would be really helpful if someone could explain how what I did fixed my problem!):First, I found this post:http://www.prestashop.com/forums/viewthread/25672/general_discussion/color_picker_is_not_working/Making this change in preferences to change the v.1.1 compatibility removed the error message "id_color_default is not defined." Even though this error message disappeared, the colour picker still did not work. I was left with one error message: unterminated string literal [break On This Error] addCombination(502, new Array('31','49'), 100, 30, 0, -1, '6/12SWL22-24 I did not know what this meant, but I could see that the error was occurring on one of the combinations. I simply deleted the combination. Once I deleted the combination, the combination/attribute box worked perfectly. Can anyone tell me what went wrong here and how these steps fixed it?Thanks. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now