Jump to content

change add button if product has options


Guest
 Share

Recommended Posts

Hi Guys,

I've been researching but can't find any info specifically on my issue, maybe you can help me out.

I'm wanting to swap the 'add to cart' button in the category and search view to the 'more' button, but only if a product has options.

This would mean that clicking the link would just take them to the product page. I am aware of mods to display the product options on the category page, but would like to keep the cat view clean and just disable people from adding a product with options directly to the cart from the cat page.

Im thinking of changes in viewCat.inc.php where there are two queries, one doing the usual product search, the other querying prod_options_bot so that if the product IDs match there can be a conditional statement to perform the swap. But I guess this would mean that the html to create the entire add to cart button would need to get parsed or the html for the more button, and neither html exist in the viewCat.tpl file for this to work. Is there a more intuative way of doing this?

Really appreciate any help!

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

 Share

×
×
  • Create New...