bsmither Posted August 23, 2013 Share Posted August 23, 2013 Not sure when product Option Sets were introduced (I think as of CC520), but it has been discovered that from the View Category page and the Latest Products area of the Homepage, a product with required options that were assigned via Option Sets can be added to the basket without first making the required selections. What is supposed to happen is the customer is to be taken to the View Product page with an 'error message' that says, "Please select required options before adding to your basket." Here is the fix: In the file /classes/catalogue.class.php, find the function getProductOptions, near line 512. About eleven lines down, find: foreach ($groups as $group) { On a new blank line after that, add this: if ($group['option_required']) $this->_option_required = true; Then, read this conversation beginning with post#7: http://forums.cubecart.com/topic/46859-resolved-required-product-options-error/ Test thoroughly! Link to comment Share on other sites More sharing options...
Dirty Butter Posted August 23, 2013 Share Posted August 23, 2013 So, for clarification, are you saying make all the edits outlined from post #7 onward outlined in the linked post AND the edits offered in this thread? Link to comment Share on other sites More sharing options...
bsmither Posted August 23, 2013 Author Share Posted August 23, 2013 Yes, you should. Link to comment Share on other sites More sharing options...
Al Brookbanks Posted December 16, 2013 Share Posted December 16, 2013 I have unpinned this as it is now default code in CubeCart. Please make sure you always use the latest version. Link to comment Share on other sites More sharing options...
Recommended Posts