MySQL Error: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '$(this).attr(") or (url = "whole-site")) ORDER BY priority desc' at line 1
SQL Statement: SELECT distinct,location,code,type FROM web_ads JOIN web_ad_pages as p on join web_ad_dates as d on and d.start_date <= '2021-09-17' and d.end_date >= '2021-09-17' WHERE web_ads.magazine_id='15' and ((url = "/services/product-design-and-testing") or (url = "/services/product-design-and-testing/" $(this).attr(") or (url = "whole-site")) ORDER BY priority desc