Skip Navigation

[Resolved] Listing site and post relationship with user

This support ticket is created 5 years, 3 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
- - 14:00 – 20:00 14:00 – 20:00 14:00 – 20:00 14:00 – 20:00 14:00 – 20:00
- - - - - - -

Supporter timezone: Asia/Ho_Chi_Minh (GMT+07:00)

This topic contains 18 replies, has 2 voices.

Last updated by FelipeP5703 5 years, 3 months ago.

Assisted by: Beda.

Author
Posts
#1349939

Well, you can set up a custom field checkbox asking "clinic or not".
If checked, another field URL and so on displays, this can be set in Toolset > Custom Fields when you edit the Custom Fields, in the conditional of each field.

You can also set up user Fields exactly the same way, such as a checkbox "show website", which you can use in HTML conditions later to show or not the website

However all this as already discussed in past will work only with ONE user (WordPress User) for EACH post.

If you have clinic owners as real users and masseuses as real users you will need to decide whom of both is gonna be the author and hence the one where you can say "can display url or not"

The difficulty here is not to display the URL, as said, with HTML condition you do that in 2 minutes.
The issue here is to decide what your content will be, and who administrates it.

If you have masseuse and they create ads and they admin themselves, then users (masseuses) are enough.
If you also have Clinic owners that must control part of this, you need at least 2 user roles, but most likely also a post type to allow connection to one post by more than one user.

I think however meanwhile to understand that only Masseuse are required as users, and they will create ads, and on those Ads the URL of the Ad can be shown or not, either depending on the User's field, or even to a particular post field only editable on the Ad by you.

#1350057

Just to conclude because I don't want to take more of your time, I have decided that Masseuses would be enough because 98% of my clients are independent, there are only 2 - 3 Clinic Owners. Therefore, I'll be creating user custom fields where I can control the features through them.

For example, to show or not the website, I created a radio user custom field with a yes or no with the default on "no." Now all users who sign up and create their custom posts will not show their website by default. So if a user is a clinic owner with 30 Masseuses (btw, only the owner of the clinic will have access to the site and the custom posts), then I switch the default radio to yes on that user, then all his custom posts should show the site, am I correct?

#1350061

This should work yes, assumed that you put the Field (radio) on the USER (so it's a user Field).

Then, all the posts that should ever display something related to that field must be crated by the same user.
Means, if you have one user creating 30 posts you can control all those 30 posts at once, because the author os the same in all of them.
So when displaying the Post, you will simply check on the Author, and then get the author field, to know if an url should be shown or not.

Please let me know if anything remains unclear - we can also re-start a fresh ticket, with the insight in mind we have now, and explore the new approach.

There is no limit in time or amount of tickets that I can dedicate to you as an User of Toolset, as long it's within the Support policy - hence please do not hesitate to consult us as much you want 🙂

#1350167

My issue is resolved now. Thank you!