b22c Posted April 22, 2013 Share Posted April 22, 2013 (edited) Hi its possible to change the product availability color, i would like to choose green to products in stock and yellow to products that take 2 days to become availability etc. Cheers Edited April 22, 2013 by b22c (see edit history) Link to comment Share on other sites More sharing options...
NemoPS Posted April 22, 2013 Share Posted April 22, 2013 Hi, If you only have one language, you can edit product.tpl and use something like this: {if $product->available_for_order == 'envio em: 2 dias'}class="yellow"{else if $product->available_for_order == 'In stock'} class="green">{/if} This, of course, for the availability wrapper. Note that you might have other classes there, take those into account Link to comment Share on other sites More sharing options...
b22c Posted April 22, 2013 Author Share Posted April 22, 2013 Hi nemo, so in prestashop backend dont have options to change the color right? Only changing the code is possible? Link to comment Share on other sites More sharing options...
tdr170 Posted April 22, 2013 Share Posted April 22, 2013 (edited) Yes but you can chnage this in CSS, edit product.css located in themes/default/css. Here is the code to change in this code I have made the background red. #availability_statut #availability_value { background-color:#E30101; color:#ffffff; text-shadow:none; padding:0 10px; text-transform: uppercase; font-size:10px; font-weight: bold; display:inline; text-align:center } Edited April 22, 2013 by tdr170 (see edit history) Link to comment Share on other sites More sharing options...
b22c Posted April 22, 2013 Author Share Posted April 22, 2013 But this change all colors of availability to red right? Instead of green like now become all red right? Link to comment Share on other sites More sharing options...
tdr170 Posted April 22, 2013 Share Posted April 22, 2013 That is correct in product view this will change all product availability colors. Link to comment Share on other sites More sharing options...
b22c Posted April 22, 2013 Author Share Posted April 22, 2013 Ok so is not possible to have green on some products and red on others and yellow on others. Only is possible use one color for all. Right? Cheers Link to comment Share on other sites More sharing options...
tdr170 Posted April 22, 2013 Share Posted April 22, 2013 Correct, availability has a common class so you either change all or none. Link to comment Share on other sites More sharing options...
b22c Posted April 22, 2013 Author Share Posted April 22, 2013 Ok 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