I've been stuck on an interesting (IE: mind numbing) question for the past few hours.
I've been trying to parse operators with regex:
([<>]=?|[!=]=)
The ones that I want are: <= >= < > == !=
==
and !=
matches great. But all the ones having to do with <
or >
doesn't on my Drupal site, even though they should theoretically work.
What I ended up doing is this: .replace(/more than/ig, ">")
And in the text write "more than
" where I would write >
, and it works! Matches perfectly and everything...
This is really really silly, but I cannot think of a reason why this issue would exist. I turned off all the filters in Drupal, and in Firebug just writing >
normally looks like >
, not escaped or anything.
I'm really confused and hope for enlightenment.
Thanks.