Skip Navigation

[Resolved] Linking to a “author” page of advertiser

This thread is resolved. Here is a description of the problem and solution.

Problem:

Let me explain in bullet form what I'm trying to achieve.
1. A user visits a single ad for example see: http://inthebunch.co.za/classifieds123/listing/off-road-2010/
2. The user then wants to see all the ads by that specific advertiser.
3. The user clicks on a link that takes them to that specific advertisers' author/archive page
4. On that page there is grid display of the advertisers' ads

Solution:

1) The user clicks on a link that takes them to that specific advertisers' author/archive page
You can setup the link to post author archive page with Views shortcode: [wpv-post-author format="link"]
For example, edit the layout "Single - Ad", the visual editor cell "Advertiser", add a line:
[wpv-post-author format="link"]
More help:
https://toolset.com/documentation/user-guides/views-shortcodes/#wpv-post-author

2) On that page there is grid display of the advertisers' ads
Createa Views wordpress archive for author archive page:

http://inthebunch.co.za/classifieds123/wp-admin/admin.php?page=view-archives-editor&view_id=6385

in section "Loops Selection", enable option "Author archives", and click "Edit" button, enable post type "Listings"
Then it will be able to display the listing posts of the specific author
More help:
https://toolset.com/documentation/user-guides/normal-vs-archive-views/

Relevant Documentation:
https://toolset.com/documentation/user-guides/normal-vs-archive-views/
https://toolset.com/documentation/user-guides/views-shortcodes/#wpv-post-author

This support ticket is created 6 years, 11 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
- 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 9:00 – 13:00 -
- 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 -

Supporter timezone: Asia/Hong_Kong (GMT+08:00)

This topic contains 12 replies, has 3 voices.

Last updated by coetzeeG 6 years, 11 months ago.

Assisted by: Luo Yang.

Author
Posts
#597029

Hi there.

Before I go ahead, I have opened a ticket with Nigel (by accident on the community forum), you can see that here: https://toolset.com/forums/topic/link-to-author-of-ads/

Nigel has been very helpful but I'm not entirely sure it's what I'm trying to do, please understand I'm not blaming him at all!

I'm essentially trying to link to the advertiser of an ad, the linked page should show a list of that advertisers' ad and other custom fields like their website, contact number etc (I know how to ad these fields)

I was hoping to schedule a video call so I can explain what I'm trying to do more visually, is this possible?

#597098

Noman
Supporter

Languages: English (English )

Timezone: Asia/Karachi (GMT+05:00)

Hi Coetzee,

Thank you for contacting Toolset support.

1. Can you please confirm that you have created two CPTs?
CPT advertiser as Parent
CPT Ad as child

2. Have you already build one to many relation between advertiser and Ad?
3. Now you want to display all child Ads on advertiser Parent page? Right?
4. Also please provide back-end screenshots of View or Page where you have tried to add the Advertisers.

Thank you

#597160

Hi Noman,

I have created the cpt for advertisers called Shops in my case.

I'm working from the reference site, so the cpt or listings was already there and I set it as a child.

Where I'm getting stuck is on the one to many relation between shops and listings.

Instead of screenshots, I can provide backend access if it will make things easier to view?

#597237

Noman
Supporter

Languages: English (English )

Timezone: Asia/Karachi (GMT+05:00)

For Implementing one-to-many relationships please follow this doc:
https://toolset.com/documentation/beyond-the-basics/post-relationship-concepts/implementing-one-to-many-relationships/

If issues still exists, please provide temporary access WP-Admin Login and FTP login info to your site. Your next answer will be private which means only you and I have access to it.

=== Please backup your database and website ===

✙ I would additionally need your permission to de-activate and re-activate Plugins and the Theme, and to change configurations on the site. This is also a reason the backup is really important.

✙ Please add the Link to the CPTs and Pages involved in this case.

Thanks

#597612

Dear Coetzee,

Our supporter Noman isn't available currently.

I checked it in your website, you have already setup the parent/child post type relationship between post type "shop" and "listing",
you can create a "shop" post, for example:
hidden link
In section "Post Relationship", there is a button "Add New Listing", there you can add more child "Listing" posts.

If you want to display the child "listing" posts of current "shop", you can create a view for it, see our document:
Querying and Displaying Child Posts
https://toolset.com/documentation/user-guides/querying-and-displaying-child-posts/

#597688

Is there possibly a way to make this process easier and more automatic by maybe using a custom author archive page that lists the advertisers' adverts they placed?

Let me explain in bullet form what I'm trying to achieve.

  • 1. A user visits a single ad for example see: hidden link;
  • 2. The user then wants to see all the ads by that specific advertiser.
  • 3. The user clicks on a link that takes them to that specific advertisers' author/archive page
  • 4. On that page there is grid display of the advertisers' ads
#597955

I assume the "advertiser" is a wordpress user, who is the post author of single listing post,
If it is, you can try these:
1) The user clicks on a link that takes them to that specific advertisers' author/archive page
You can setup the link to post author archive page with Views shortcode: [wpv-post-author format="link"]
For example, edit the layout "Single - Ad", the visual editor cell "Advertiser", add a line:
[wpv-post-author format="link"]
hidden link
More help:
https://toolset.com/documentation/user-guides/views-shortcodes/#wpv-post-author

2) On that page there is grid display of the advertisers' ads
Createa Views wordpress archive for author archive page:
hidden link
in section "Loops Selection", enable option "Author archives", and click "Edit" button, enable post type "Listings"
Then it will be able to display the listing posts of the specific author
More help:
https://toolset.com/documentation/user-guides/normal-vs-archive-views/

#598303

Hi Luo Yang,

Thank you veerryy much, I think this is the right solution 🙂

One thing, where you say "Createa Views wordpress archive for author archive page:" I don't see a link, just the words "hidden link"

#598307

Oh wait, never mind, the links are displaying now.

I am going to keep the thread open, just in case, but will reply and close as soon as I was successful.

#598354

OK, please update this thread if you still need assistance for it.

#599141

Hi Luo Yang,

2 things.

Go to this ad: hidden link then click on the edditest123 link.

You'll notice that when you click the link that it goes to the home page instead of the author page.

the second thing, how do I add content to the author page, do I edit the view or the content template?

#599164

Q1) Go to this ad: hidden link then click on the edditest123 link.
It is a new question, It depends on how do you setup the "edditest123 " link, if you are going to display a CRED form edit link, please follow our document to setup it:
Displaying CRED editing forms
https://toolset.com/documentation/user-guides/displaying-cred-editing-forms/

If you still need assistance for it, please create new thread for the new question, that will help other users to find the answer

Q2) the second thing, how do I add content to the author page, do I edit the view or the content template?
You can edit the Views wordpress archive for author archive page:
hidden link
And add your content to where you want, more help:
WordPress Archive – Customizing the Appearance of Archive Pages
https://toolset.com/documentation/user-guides/normal-vs-archive-views/

#600817

Will open a new topic.