Home › Forums › Product Support Forums › Ajax Search Pro for WordPress Support › Overriding Ajax Search Pro CSS › Reply To: Overriding Ajax Search Pro CSS
September 12, 2024 at 5:37 pm
#49268
Participant
Hi Ernest,
Thanks for the prompt replay.
The only problem I had with that solution, it is targeting a specific search instance, and I need CSS for all 4 search instances I have.
So, I used something called attribute selectors.
Instead of:
div#ajaxsearchpro4_1 .probox .proinput input.orig,
div#ajaxsearchpro4_2 .probox .proinput input.orig {
padding: 12px !important;
}
I used:
div[id*="ajaxsearchpro"].probox .proinput input.orig {
padding: 12px !important;
}
It works also with classes:
div[class*="asp_m_"].asp_m.asp_main_container .probox .proinput input.orig {
color: #1A213D !important;
font-size: 1rem !important;
}
It does not work 100% of the time, I had one case that I had to use specific ID selector.
Hopefully, this will help someone.
Ernest, this ticket can be closed.
Best,
Yan