Trying to get property of non-object wordpress error message

Given that the page works if you leave the original query alone, your solution is pretty simple. Leave the original query alone. You don’t need to overwrite that query in order to created secondary loops. Instead of this: query_single(‘dealers’, ‘publish’, ‘1’, $taxtype, $value); if (have_posts()) : while (have_posts()) : the_post(); You want: $myq = new … Read more

Returning error upon comment being flagged as spam

This is how I’ve handled passing messages back to the user before: within your current function, set a transient with your message: set_transient( ‘admin_notice’, ‘Please put down your weapon. You have 20 seconds to comply.’ ); Then add a new hooked function: function admin_notices() { $notice = get_transient( ‘admin_notice’ ); if ( $notice ) { … Read more

Why do these errors appear on my wordpress site? [closed]

It is likely a callback function for something. My guess is that somewhere something is trying to use a function named mytheme_admin_bar_render as a callback but that function has not been defined. Something like… add_filter(‘something’,’mytheme_admin_bar_render’); … possibly but there are many, many possibilities. grep your wp-content folder for mytheme_admin_bar_render, or use an IDE that can … Read more

403 Forbidden error nginx

Issue was resolved by commenting the code that was requesting the jquery file from www.jquerye.com site. But as that site is expired the jquery link too which was giving 403 Forbidden error. I found that piece of code in themes/themename/framework/functions/init.php file with cURL requests. I have commented the last line which was adding to wp_head … Read more

When sorting WP_List_Table, table sorts, but I also get SQL errors

the part ORDER BY $orderby $order LIMIT get translated to ORDER BY asc LIMIT, the columnname that supose to be in $orderby is missing, and there for the sql fail. looks like you want your default value to be ‘title’ $orderby = (isset($_REQUEST[‘orderby’]) && in_array($_REQUEST[‘orderby’], array_keys($this->get_sortable_columns()))) ? $_REQUEST[‘orderby’] : ‘title’; may geuss is that in_array() … Read more

Parse error:syntax error [closed]

use single quotes outside of the following statement, why you are getting this error because you are using double quotes for class attribute “</span><span class=”meta-sep”>|</span>” and also wrapping it in double quotes. replace this “</span><span class=”meta-sep”>|</span>” with ‘</span><span class=”meta-sep”>|</span>’ or vice versa “</span><span class=”meta-sep”>|</span>” <?php the_tags( ‘<span class=”tag-links”><span class=”entry-utility-prep entry-utility-prep-tag-links”>’ . __(‘Tagged ‘, ‘your-theme’ ) … Read more

WordPress database error You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version [closed]

There are multiple ways to fix this. You can either remove the if-condition containing SHOW TABLES LIKE (remove lines: 117, 135 and 137, 157). That should work as the dbDelta function checks itself if the tables are already presend. Or you could just add some single quotes to the table names in the lines 117 … Read more