GK News Show Pro, avoiding duplicate posts

Responsive WordPress theme for musicians, bands, artists - easy to configure and various theme features.
GK User
Mon Feb 10, 2014 9:37 pm
Hi - fantastic theme, thank you!

I am using the GK News Show Pro as a widget in the sidebar where single posts are shown.
However, when the single post comes from the same category as being shown in GK News Show Pro, the single post and one of the widget's posts are duplicated.

See attached.

Is there any way to avoid this duplication?
I am a coder, so happy to make manual changes to the widget code is need be.

Many thanks,
Simon
User avatar
Fresh Boarder

GK User
Tue Feb 11, 2014 7:45 am
You would need to modify widgets database query by excluding current post. I think using post_id is the only available method. Please check this documentation:
http://wordpress.stackexchange.com/ques ... m-wp-query
focusing on 'post__not_in' argument.

The file to edit is this one:
/wp-content/themes/RockWall/gavern/widgets.nsp.php

The only problem might be in accessing current post ID inside widgets code.
User avatar
Moderator

GK User
Thu Feb 13, 2014 1:56 pm
Ok, thanks - so long as I know it's a coding issue.
User avatar
Fresh Boarder

GK User
Fri Feb 14, 2014 4:33 pm
And sadly not easy one.
If you will be able to make this idea work, please post here what and where you have changed.
User avatar
Moderator

GK User
Thu Apr 17, 2014 6:18 pm
I'm also curious if you were able to find a solution for this...
User avatar
Fresh Boarder


cron