"active" class indicator with certain URL variable strings?
I have a page with some short cut buttons enabled by the WA search features. The href is something like "index.php?sqft=1500&sqft_2=2500&Search=Find". I'd like to have those buttons add class styles to indicate which is active. I've done lots of poking around in searches online to find code that works, but I haven't hit on the right one.
I'm looking for two if statements:
- If the URL string contains "sqft=1500", echo "active"
- If the URL string does not contain a variable, echo "active" (for the "All" button)
Any direction would be greatly appreciated.