Digital experiences for all disciplines
Forum Replies Created
-
Posted in: We hit Power Elite.
-
August 23, 2013 at 6:58 pm in reply to: Modify the portfolio-carousel.php to display custom post types #17958This reply has been marked as private.August 23, 2013 at 11:47 am in reply to: Modify the portfolio-carousel.php to display custom post types #17899
ok, it comes down to this bit of the code for functions.php:
$args = wp_parse_args( $args, array(
‘post_type’ => $post_type,
‘post__not_in’ => array($post_id ),
‘taxonomy’ => $taxonomy
) );With it – the thumbnails of the current post are shown over and over again.
Without it – only one thumb of the current post shows – no related items.
This is the same behavior if I remove the ‘article-category’ part from the
$related_posts_query = related_posts_by_taxonomy( $post->ID, ‘article-category’ );
which replaces the original on line 247 of single.php
$related_posts_query->the_post();
So, I’m clearly no expert but I would say that the query is dodgy… perhaps Pippin will shine a light upon the situation.
Never mind, could be time for that developer I guess …and several beers for me!
Ciao ;0)
August 23, 2013 at 9:42 am in reply to: Modify the portfolio-carousel.php to display custom post types #17854Ed,
Think I was perhaps barking up the wrong tree and went off on a tangent!
I have gone back to the code you provided and it seems the continuous stream of thumbs likely indicates that the code is missing something…
$related_posts_query = related_posts_by_taxonomy( $post->ID, ‘article-category’ );
A. = a continuous stream of thumbnails of the current post – no related items present.
$related_posts_query = related_posts_by_taxonomy( $post->ID, ” );
B. = one thumb displayed – but this is the current post, not the related one.
So I finally admit defeat! lol – thanks for all your help on this Ed, can’t believe this little issue is such a tricky bugger!
So on that note let’s close this thread shall we as everything else is good and my migration begins Monday…
Have a great weekend!
Regards
Sam
August 22, 2013 at 11:30 am in reply to: Modify the portfolio-carousel.php to display custom post types #17647Good afternoon Ed,
Thought id give it one last go myself – after some digging it turns out Pippin (easy content types) has a plugin called ‘related posts by taxonomy’ which supposedly provides the correct code for this and allows me to replace $related_posts_query->the_post(); with a simple echo pippin_related_posts();
This works but strangely the output is also a continuous stream in the same way the solution you provided yesterday!
I have disabled all plugins except: Easy Content Types, Custom Post Type Permalinks and Related Posts by Taxonomy.
I am not sure how to proceed – I could add echo pippin_related_posts(); to the 2013 theme to see if it works but that doesn’t really help me! …I have now contacted Pippin for some advice.
Thanks for all your help here Ed, if you do have any thoughts as to what may be causing this please do let me know.
Regards
Sam
August 21, 2013 at 6:48 pm in reply to: Modify the portfolio-carousel.php to display custom post types #17563This reply has been marked as private.August 21, 2013 at 6:39 pm in reply to: Modify the portfolio-carousel.php to display custom post types #17562This reply has been marked as private.August 21, 2013 at 6:31 pm in reply to: Modify the portfolio-carousel.php to display custom post types #17559This reply has been marked as private.August 21, 2013 at 6:19 pm in reply to: Modify the portfolio-carousel.php to display custom post types #17555This reply has been marked as private.August 21, 2013 at 5:42 pm in reply to: Modify the portfolio-carousel.php to display custom post types #17551This reply has been marked as private.August 21, 2013 at 5:25 pm in reply to: Modify the portfolio-carousel.php to display custom post types #17550This reply has been marked as private.August 21, 2013 at 5:11 pm in reply to: Modify the portfolio-carousel.php to display custom post types #17548This reply has been marked as private.August 21, 2013 at 4:40 pm in reply to: Modify the portfolio-carousel.php to display custom post types #17542This reply has been marked as private.August 20, 2013 at 5:50 pm in reply to: Modify the portfolio-carousel.php to display custom post types #17417This reply has been marked as private.August 20, 2013 at 3:14 pm in reply to: Modify the portfolio-carousel.php to display custom post types #17379This reply has been marked as private.August 20, 2013 at 2:54 pm in reply to: Modify the portfolio-carousel.php to display custom post types #17363This reply has been marked as private. -
Posted in: We hit Power Elite.