Ajax filter through JavaScript with AND, OR condition

i see no use of an or condition in your script. you also have to use appropriate brackets if you don’t want to rely on the default precedences: and > or. further you have type mismatches - you are speaking of x = 1 but the script says x = yes for the flag.