wasferraz
Forum Replies Created
-
Forum: Fixing WordPress
In reply to: Show custom taxonomy name at loop.Please fellas, help-me!!
Forum: Themes and Templates
In reply to: List posts only from authors level?I can’t do your last reply, help me!
Forum: Themes and Templates
In reply to: List posts only from authors level?MichaelH, in your code how can I limit to show only 2 posts a time?
Becouse in your code, if I have 10 Authors, it shows the 10 authors last post. I need to show Only the last 2 independing the total of authors.
Can you help me?
Forum: Themes and Templates
In reply to: List posts only from authors level?Thanks for the reply, but, in case of the code above it defines one author and list 2 posts of him.
What I need is list the last 2 posts posted by author’s role, and not the last 2 posts of one only author.
See my website in the link below:
https://www.informecidade.com/portalIn the section “Artigos Mais Recentes de Counistas” – “Most Recente Articles from Columnists” I want to list the most recente posts from my columnists, that were registered at admin like “Authors”.
The rest content of my website are posted by me, and I am the Admin of it. This is the why I don’t need my posts listed in that section, becouse that section is only to list the Columnists “Authors” posts.
Is now easier to understand what I need?
Sorry if I not explained better before!
Forum: Themes and Templates
In reply to: List posts only from authors level?Hi MichaelH, no, I need list the last 2 posts from authors role, ordered by date in my homepage. But I need only authors role. Excluding from this list, posts by Admins and others roles.
As you say, turning off the highlighting in result documents solve the problem. I’m will wait the next version of this splendid plugin!
Thanks msaari!
Hi msaari, thanks for reply, see the link below please:
https://www.informecidade.com/portal/?site_section=site-search&s=geeks
Forum: Plugins
In reply to: [Relevanssi - A Better Search] [Plugin: Relevanssi] Search result countI have the same problem!
Forum: Fixing WordPress
In reply to: How can i list posts only from Authors, excluding admins users.The changes have not worked, I think is becouse I don’t know nothing about PHP. ;( rsss
Forum: Fixing WordPress
In reply to: How can i list posts only from Authors, excluding admins users.aphill70, the author name don’t show with any option in the codex.
And how i do to show only 2 posts?
Thanks!
Forum: Fixing WordPress
In reply to: How can i list posts only from Authors, excluding admins users.aphill70 thanks for all your help man!
Forum: Fixing WordPress
In reply to: How can i list posts only from Authors, excluding admins users.the_author_meta( 'user_nicename', $nonAdmin->author );
like this dont solve the problem.
;(
Forum: Fixing WordPress
In reply to: How can i list posts only from Authors, excluding admins users.echo "<a href=\"$nonAdmin->guid\"></a>";
the link code above function very well and link to correct place,
the only thing is that in the status bar it shows the link structure type like: https://www.mysite.com/?p=139 – but it doesn’t matter.And about the author’s name that don’t show? You have any idea?
Forum: Fixing WordPress
In reply to: How can i list posts only from Authors, excluding admins users.Hey man, let’s finish this? lack a little!
Well was missing the letter “n” in the spelling of the variable “nonAdmin” in some places. I fix it and work.
Now the thumbnail is being displayed, the title and date also are displayed correctly.
Isn’t correctly displayed the name of the author.
And permanlink is pointing to the wrong place.
The code is above:
<?php global $post; $nonAdminPosts = get_posts(array('author' => -1)); foreach($nonAdminPosts as $nonAdmin): echo " <li><a href=" ">$nonAdmin->post_title</a></li> "; echo get_the_post_thumbnail( $nonAdmin->ID, 'thumb-size' ); the_author_meta( 'user_nicename', $nonAdmin->ID ); echo $nonAdmin->post_date; endforeach; ?>