Replace classic PHP with Wordpress detection