Using WP Rewrite to rewrite custom urls in this scenario But products are loaded via GET variables.. like /?slug=product_info.php&products_id=38 but on your code, it seems that when there is product get variable it will only redirect to /?slug=product_info.php