• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

XF 1.2 Search Result Treatment

tonmo

Active member
#1
I'd like to add something to extra.css to differentiate the way results appear, depending on whether the result points to a Page, or a Post, or something else. For example, maybe "Page" results should have a green background. Can someone point me in the right direction?
 

Brogan

XenForo moderator
Staff member
#2
You can use the various classes:

.searchResult .post .primaryContent
.searchResult .thread .primaryContent
.searchResult .page .primaryContent