Assign Json file to WP_Query

Found the solution. $wp_query returns an array of objects. Therefore when decoding the json set teh second parameter to false like so json_decode($str, false); Then assign the returned values to object vars like so: if (is_file($file)){ $str = file_get_contents($file); $my_query_raw = json_decode($str, false); $my_query1 = null; $wp_query = null; $my_query1 = new WP_Query; $posts_son = … Read more

Disable feed cache for custom RSS feed?

I know the question is over a year old, and you probably already found a solution. In case this helps someone, here is a solution I came up with that adds a feed on an init hook, removes it when the plugin is deactivated, and also adds it back when the plugin is re-activated. The … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)