As this plugin won’t be updated for quite some time, I decided to go ahead and try to do it myself.
Not being a developer nor knowing php, I’m hoping to get some clarification about the following error message after updating the code (based on the EE documentation):
Error Error Number: 1054 Unknown column ‘exp_channels.blog_name’ in ‘field list’ SELECT exp_channel_titles.url_title, exp_channel_titles.title, exp_channel_titles.entry_id, exp_channel_titles.status, exp_channel_titles.expiration_date, exp_channel_titles.author_id, exp_channels.blog_name FROM exp_channel_titles, exp_channels , exp_category_posts WHERE exp_channel_titles.channel_id=exp_channels.channel_id AND exp_category_posts.entry_id=exp_channel_titles.entry_id AND exp_category_posts.cat_id=‘1’
The code in question relates to a SQL query string:
// Create SQL query string
$todo = "SELECT ".$distinctoperator." exp_channel_titles.url_title, exp_channel_titles.title, exp_channel_titles.entry_id, exp_channel_titles.status, exp_channel_titles.expiration_date, exp_channel_titles.author_id, exp_channels.blog_name FROM exp_channel_titles, exp_channels ".$categorytablesclause." WHERE exp_channel_titles.channel_id=exp_channels.channel_id ";
$todo .= $entryidequalityclause.$categoryidclause.$channelclause.$urltitleclause.$entryidclause.$statusclause.$authoridclause.$siteclause.$groupbyclause.$havingclause;
//echo '$todo: '.$todo.'
';
// Perform SQL query
$query = $this->EE->db->query($todo);Note that the plugin works fine in 1.6.9. The original query is:
// Perform SQL query
$query = $DB->query($todo);Any help would be greatly appreciated.
I have attached the plugin file to this post.
Packet Tide owns and develops ExpressionEngine. © Packet Tide, All Rights Reserved.