G Dubyah Posted May 16, 2017 Share Posted May 16, 2017 I've got an issue with the price and "Add to Basket" showing on the category screen, especially when using the options system, I don't want this to show, if it can't be done, IMO it makes the options system useless ! and every produc will have to be entered as a separate product. Quote Link to comment Share on other sites More sharing options...
Dirty Butter Posted May 16, 2017 Share Posted May 16, 2017 I don't use Options, so I can't speak to that. But I don't show Add to Basket on Latest Listings or on Category listings. The only Add to Basket I have is on the Product Listing. On content.homepage.php you will find this: {* Remove comment if you want info button <a href="{$product.url}" title="{$product.name}" class="button tiny secondary left">{$LANG.common.info}</a> *} You can change the language for Info to whatever suits your store. Then you can comment out the Buy button and price if you want. Just be sure you save a stock version before you start experimenting. Once you've figured out what you need there, you may be able to make the appropriate changes to content.category.php. Quote Link to comment Share on other sites More sharing options...
havenswift-hosting Posted May 16, 2017 Share Posted May 16, 2017 The other option is this plugin https://www.cubecart.com/extensions/plugins/category-product-options which shows and allows a product's options to be selected on the category listing page so that the add to basket does exactly that ! Ian Quote Link to comment Share on other sites More sharing options...
G Dubyah Posted May 16, 2017 Author Share Posted May 16, 2017 2 hours ago, Dirty Butter said: I don't use Options, so I can't speak to that. But I don't show Add to Basket on Latest Listings or on Category listings. The only Add to Basket I have is on the Product Listing. On content.homepage.php you will find this: {* Remove comment if you want info button <a href="{$product.url}" title="{$product.name}" class="button tiny secondary left">{$LANG.common.info}</a> *} You can change the language for Info to whatever suits your store. Then you can comment out the Buy button and price if you want. Just be sure you save a stock version before you start experimenting. Once you've figured out what you need there, you may be able to make the appropriate changes to content.category.php. My HTML skills are not up to this ! Quote Link to comment Share on other sites More sharing options...
Dirty Butter Posted May 16, 2017 Share Posted May 16, 2017 I'm sorry!!!! I forgot you are using Mican! So few people provide a signature I'm out of the habit of looking. i'll download Mican and see what I can do. Quote Link to comment Share on other sites More sharing options...
G Dubyah Posted May 16, 2017 Author Share Posted May 16, 2017 3 minutes ago, Dirty Butter said: I'm sorry!!!! I forgot you are using Mican! So few people provide a signature I'm out of the habit of looking. i'll download Mican and see what I can do. It's Broad actually !! Quote Link to comment Share on other sites More sharing options...
Dirty Butter Posted May 16, 2017 Share Posted May 16, 2017 Broad is based on Foundation. So make a good copy of content.homepage.php and save it. We'll take baby steps and see if you can get more comfortable with the code. See if you can take off the {* *} around the code, so the Info Button shows on your listings (of course I'm assuming the code is there). Quote Link to comment Share on other sites More sharing options...
G Dubyah Posted May 16, 2017 Author Share Posted May 16, 2017 Hi thanks. Yes the code is there, and I've got a master copy, and edited a copy of that. Quote Link to comment Share on other sites More sharing options...
Dirty Butter Posted May 16, 2017 Share Posted May 16, 2017 So is the Info button now showing where you want it? Quote Link to comment Share on other sites More sharing options...
G Dubyah Posted May 16, 2017 Author Share Posted May 16, 2017 Not sure I wanted the info button, but yes one is showing. and it does take me to the product when clicked on What I really need is to get rid of the "add to basket" button on multiple options, Quote Link to comment Share on other sites More sharing options...
Dirty Butter Posted May 16, 2017 Share Posted May 16, 2017 Oh - I misunderstood - I thought you were trying to get all the options/price/add to cart button stuff off the Category listing of Products. Quote Link to comment Share on other sites More sharing options...
G Dubyah Posted May 16, 2017 Author Share Posted May 16, 2017 1 minute ago, Dirty Butter said: Oh - I misunderstood - I thought you were trying to get all the options/price/add to cart button stuff off the Category listing of Products. Ok lets start again ! If you go to my site and click on "Paints" on the Navbar, it takes you to the category page, one category is Own Brand Acrylics, the other is Humbrol Enamels. Both of these are showing an "add to basket" button and a price. What I want to do is remove the button and price from category pages for all categories, is this possilbe ? Quote Link to comment Share on other sites More sharing options...
Dirty Butter Posted May 16, 2017 Share Posted May 16, 2017 What's your url? No sooner asked than I saw it. BRB Yes, removing buttons is a matter of finding the section in the code and putting {* has to have a space before the code.... and a space before the asterisk *} around it. Find this section and comment it out with braces and asterisks. Just remember I'm guessing!! {if $product.ctrl_sale}<span class="old_price">{$product.price}</span> <span class="sale_price">{$product.sale_price}</span> {else} {$product.price} {/if} Quote Link to comment Share on other sites More sharing options...
bsandall Posted May 16, 2017 Share Posted May 16, 2017 You should be able to remove some lines from `content.category.php` to achieve your desired result. I removed all of the code between lines 98 and 128 (if using unmodified code): // keep this line and the closing div - remove everything else <div class="small-3 columns"> <h3> {if $product.ctrl_sale}<span class="old_price">{$product.price}</span> <span class="sale_price">{$product.sale_price}</span> {else} {$product.price} {/if} </h3> {if $product.available <= 0} <div class="row collapse"> <div class="small-12 columns"> <input type="submit" value="{$LANG.common.unavailable}" class="button small postfix disabled expand marg-top" disabled> </div> </div> {* ctrl_stock True when a product is considered 'in stock' for purposes of allowing a purchase, either by actually being in stock or via certain settings *} {elseif $product.ctrl_stock && !$CATALOGUE_MODE} <div class="row collapse"> <div class="small-4 columns"> <input type="text" name="quantity" value="1" class="quantity text-center"> </div> <div class="small-8 columns"> <button type="submit" value="{$LANG.catalogue.add_to_basket}" class="button small postfix">{$LANG.catalogue.add_to_basket}</button> </div> </div> {elseif !$CATALOGUE_MODE} <div class="row collapse"> <div class="small-12 columns"> <input type="submit" value="{$LANG.catalogue.out_of_stock_short}" disabled class="button disabled expand small"> </div> </div> {/if} </div> That does not affect the home page nor the side bars (e.g. best sellers), but you can look around in the skin templates for similar code and change as desired. Quote Link to comment Share on other sites More sharing options...
G Dubyah Posted May 16, 2017 Author Share Posted May 16, 2017 I havew a lot more code in that section ! Quote Link to comment Share on other sites More sharing options...
bsandall Posted May 16, 2017 Share Posted May 16, 2017 6 minutes ago, G Dubyah said: I havew a lot more code in that section ! Do you understand HTML / SMARTY at all? If so, compare the parts that I deleted above and remove those from your code. If not, you may need to hire a developer to help you. Quote Link to comment Share on other sites More sharing options...
bsandall Posted May 16, 2017 Share Posted May 16, 2017 One thing I forgot to mention is that it is now possible to designate 'default' options for your products; doing so will allow the 'Add to Basket' button to work directly from the catalogue or home page. Note, however, that the database query that requests the product price does not yet query options at all, so you should set the overall product price to whatever it is for the default set of options. Quote Link to comment Share on other sites More sharing options...
Dirty Butter Posted May 16, 2017 Share Posted May 16, 2017 29 minutes ago, G Dubyah said: I havew a lot more code in that section ! That's why I was trying to do this in small steps. 1 Quote Link to comment Share on other sites More sharing options...
G Dubyah Posted May 17, 2017 Author Share Posted May 17, 2017 12 hours ago, Dirty Butter said: That's why I was trying to do this in small steps. That's why I didn't touch it ! Had to go to bed last night as it was getting really late in the UK. Quote Link to comment Share on other sites More sharing options...
keat Posted May 17, 2017 Share Posted May 17, 2017 There are at least two very good plugins available to populate the category pages with options. 14 hours ago, bsandall said: One thing I forgot to mention is that it is now possible to designate 'default' options for your products; doing so will allow the 'Add to Basket' button to work directly from the catalogue or home page. Note, however, that the database query that requests the product price does not yet query options at all, so you should set the overall product price to whatever it is for the default set of options. @bsandall Where is this option please. Quote Link to comment Share on other sites More sharing options...
bsandall Posted May 17, 2017 Share Posted May 17, 2017 @keat When you are editing or adding a product's options, there is a new column, 'Default', with a checkbox. Set one option per required option group as the default to allow it to be added directly via the 'Add to Basket' button. Furthermore, any option set as the default will automatically be selected when first viewing the product page. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.