stiwi
Forum Replies Created
-
Hi mitcho,
thx for your answer. Unfortunately there are no results anyway.
Maybe I have an answer (can you confirm that?): I set up a new wordpress system. After that I import all posts from another wordpress system. After that I installed YARPP. Now I have no related post, because all posts were written in the database by importing them. So YARPP can’t “crawl” through the informations like headlines, text,.. because I do not create further posts.
Could that be?
By the way: After the installation YARPP there was an alert, that I have to approve that a database mode options is activated which is required for YARPP. Maybe there’s a mistake? What do you think?
Thank you so much for your help. I really despair of it :((
Stefan
Okay I replaced the new code with:
<?php related_posts() ?>
But if I choose the YARPP Template: “yarpp-template-random.php” I get the following output in the frontend:
Related Posts
No related posts were found, so here’s a consolation prize: .
If I replace the old code (see above) with the following code:
<?php if ($related_query->have_posts()):?> <ol> <?php while ($related_query->have_posts()) : $related_query->the_post(); ?> <?php if (function_exists('has_post_thumbnail')): if (has_post_thumbnail()):?> <li><a href="<?php the_permalink() ?>" rel="bookmark" title="<?php the_title_attribute(); ?>"><?php the_post_thumbnail(); ?></a></li> <?php endif; endif; ?> <?php endwhile; ?> </ol> <?php else: ?> <p>No related photos.</p> <?php endif; ?>
I get the following error:
Fatal error: Call to a member function have_posts() on a non-object in /srv/www/spass-junkies.de/v2/wp-content/themes/graffitiblue/single.php on line 75
I don’t know how to deal with this issue ??
Hey mitcho!
Thanks for your answer! ??
Oh okay I did not know that I can’t use the yarpp_sql query. And unfortunately I don’t know how to fix it ??
Could you give me an exeample how fix the code you see above?
Thanks in advance ??
Stefan