- This topic has 15 replies, 5 voices, and was last updated 3 years, 2 months ago by
Scott.
-
AuthorPosts
-
February 11, 2023 at 2:15 pm #2529862
Py
The author page url domainname.com/author/username/ returns Nothing Found.
Should I enable some setting first?
Can the Author page be built with Elements?
I have both GeneratePress Pro and GenerateBlocks Pro
I want the author page to look exactly like this page I have built for blog posts feed: https://passivebook.com/articles/ with an author box on top and the posts filtered for the respective author.
February 12, 2023 at 4:37 am #2530197David
StaffCustomer SupportHi there,
does the author whose archive you’re looking for have any Posts Published ?
February 13, 2023 at 6:05 am #2531409Py
I don’t use posts in WordPress. I only use pages. How do I display the pages published by the author and exclude some pages based on taxonomy?
February 13, 2023 at 11:03 am #2531898David
StaffCustomer SupportTry this PHP Snippet:
function author_pages_pre_get_posts( $query ) { if ( $query->is_author() && $query->is_main_query() ) { $query->set( 'post_type', array( 'page', 'post' ) ); $query->set( 'category__not_in', array( 20, 30, 40 ) ); } } add_action( 'pre_get_posts', 'author_pages_pre_get_posts' );Change the IDs in the
array( 20, 30, 40 )to match the categories you want to exclude.February 15, 2023 at 11:35 am #2534586Py
Hi David
I added the code you shared in the snippet plugin but the author page still says Nothing Found
Please check this post: https://passivebook.com/blogging/start-a-blog/history/
The author link is here: https://passivebook.com/author/abhishek/ (Also available in the meta below the title)
February 15, 2023 at 11:59 am #2534604Ying
StaffCustomer SupportHave you disabled the author archive link in your SEO plugin?
The author archive link has been redirected to the homepage.
February 16, 2023 at 9:02 am #2535789Py
You were right. Thank you
Can I customize my page with Generate Blocks? Basically, I want to make my Author Page look like this: https://passivebook.com/articles/
February 16, 2023 at 9:32 am #2535835David
StaffCustomer SupportYou can create a new Block Element – Loop Template and set it to your Author Archives:
https://docs.generatepress.com/article/block-element-loop-template/
You can then add whatever content you want, and for the post loop you can use a Query Loop Block, with the option “Inherit Query from Template” selected.
February 18, 2023 at 9:56 am #2538168Py
I have added Social Media Links to the Author Profile using the code here: https://wpknifer.com/add-social-media-links-to-the-author-profile/
I want to display it on the author archives page.
I am using Buttons with Author Meta as shown below:
[img]https://i.imgur.com/cs7JaY1.png[/img]How do I ensure the button is not displayed if there is no link in the author bio?
Also how do I make the image rounded? I am using Dynamic Image from GenerateBlocks
Here is how it looks now:
[img]https://i.imgur.com/dTvVU6E.png[/img]Here is how I want it to look
[img]https://i.imgur.com/Oa2I8Bk.png[/img]February 18, 2023 at 2:15 pm #2538296Scott
Hey David,
How coukd this snippet be altered in the array line to exclude all, or is it a must to list individually?
February 19, 2023 at 3:02 am #2538539David
StaffCustomer SupportHi Py,
if there is no link in the custom field then the button should automatically be removed.
for your second issue, select the Image Block, an increase its Spacing > Border radius to a much larger value on all sides.
Hi Scott,
could raise a new topic?
February 19, 2023 at 6:44 am #2538689Py
February 19, 2023 at 8:52 am #2538920David
StaffCustomer SupportChange that Block for a GenerateBlocks Image Block, there you have the GB Spacing Settings and its own Dynamic Data options
February 19, 2023 at 9:40 am #2538974Py
I have done this change but the image still doesnt get rounded.
Here is the setting: https://www.screencast.com/t/x4P0Mwjy0g
Here is out it looks: https://passivebook.com/author/abhishek/
February 19, 2023 at 5:42 pm #2539187Fernando Customer Support
Hi Py,
Did you add this code?:
img { height: auto; max-width: 100%; border-radius: 8px!important; }It’s overriding the border-radius setting you have.
Try removing it from Appearance > Customize > Additional CSS.
-
AuthorPosts
- You must be logged in to reply to this topic.
