Add css only in one product page

  • Posts: 85
  • Thank you received: 1
7 years 6 months ago #282961

-- HikaShop version -- : 3.2.1
-- Joomla version -- : 3.8.2

Hi
i ' d like to ask you if its possible to add a class only in one element in a product page without to effect other product pages.
For example to change the color in a button in red only in one product pages and the others buttons in product pages to keep the original color.
Attached an example

thanks in advance!

Attachments:

Please Log in or Create an account to join the conversation.

  • Posts: 83932
  • Thank you received: 13588
  • MODERATOR
7 years 6 months ago #282972

Hi,

Yes, it's possible.
If you look at the HTML of the area, you can see that there is a parent div which has a unique id for each product of the listing.
For example:
monosnap.com/file/Iv9asKU6PGPxHP4vUPnE1DiFjOoig6
So for that product of my screenshot, you can do:
#div_hikashop_category_information_module_140_3063 .hikacart{ background-color: red !important; }
And the background color of the add to cart button will be red for that particular product with the id 3063 on the products listing of the module with the id 140.

The following user(s) said Thank You: oxygenvisual

Please Log in or Create an account to join the conversation.

  • Posts: 85
  • Thank you received: 1
7 years 6 months ago #282990

GREAT!!

thank you very mauch!!

Please Log in or Create an account to join the conversation.

Time to create page: 0.052 seconds
Powered by Kunena Forum
loading