skip to Main Content

Using Shopify to run a site. Have limitations on the platform.

Want to specifically style a class that’s tag to a specific ID inside a div.

div class pplr-wrapper is repeated pages to pages. However div id & data-id are unique from pages to pages, thus targeting specifically.
Reference

Tried styling it with the CSS code below

div#1947011350631 div.pplr-wrapper.pplr-power-supply span[ class^="pplr-drop-item _pplr_1.6_kilowatt_evga"] {
color: red;
}

Not able to make any changes with it

2

Answers


  1. Chosen as BEST ANSWER

    Solved it myself. Calling it out with the code below

    div#pplr-1947011350631.product-personalizer.pplr_background div.pplr-wrapper.pplr-power-supply span[ class^="pplr-drop-item _pplr_1.6_kilowatt_evga"]


  2. I’m not sure I understand you correctly, but this answer assumes that you want to target the span only when it’s inside that unique id.

    That looks like a un-necessary long selector (and I think your error might be that you have a space inside the attribute selector (span[ class should be span[class), but I think you could reduce the selector to this:

    #1947011350631 .pplr-drop-item._pplr_1.6_kilowatt_evga {}

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search