Skip Navigation

[Resolved] Considering moving over to Toolset

This support ticket is created 4 years, 12 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/Karachi (GMT+05:00)

This topic contains 5 replies, has 2 voices.

Last updated by John Mac 4 years, 11 months ago.

Assisted by: Waqar.

Author
Posts
#1431671

Tell us what you are trying to do?
Hello guys. I'm working on a fairly complex WP site for a client. I have done most of the work, but I'm running into some limitations. So I was considering to rebuild some of the stuff using Toolset.

But I got a bunch of questions. And I'm thinking it would be a lot quicker and time-saving to handle that over a short Zoom call instead of spending hours on support messages back and forth. I could basically just show you the backend of the site, what I did, and you could say yes or no for each section. You could also quickly point me to what module to use in Toolset to do the same setup, without having to show me any technical setup.

This would be awesome, and it would save a lot of time for both of us 🙂

What is the link to your site?
hidden link

John Mac

#1432375

Hi John,

Thank you for contacting us and I'd be happy to assist.

I'm afraid, setting up a live video call won't be possible, but you're welcome to share your specific questions or concerns through a video/screencast and we'll be able to assist you point-by-point.

You can use any video capture-and-share service like "Loom" ( hidden link ) or use your own preferred application and upload it on a file-sharing service like Google Drive, OneDrive, Dropbox, etc.

It would also help if you could share temporary admin login details to access the website's admin area and I've set your next reply as private so that you can share all this information securely.

Note: Although no changes will be made on your website, please make a complete backup copy, before sharing the access details.

regards,
Waqar

#1433211

Explainer video is done!

Link in the private message above.

#1434231

Hi John,

Happy New Year and thank you for sharing that video.

I'll watch it thoroughly and will share a point-by-point reply, by tomorrow.

Note: Sorry about the delay, but we've been a little short on coverage, due to holidays.

Thank you for your patience and understanding.

regards,
Waqar

#1437495

Hi John,

Thank you for waiting, while I reviewed the video and your existing website's set up.

Based on those observations and some tests that I performed on my own website, here are my findings:

1. Post relationship - structure:

The main limitation that you're currently facing, is that you can't link posts from one post type with another. The good news is that Toolset seamlessly offers this as a built-in feature "post relationships":
https://toolset.com/documentation/post-relationships/

You can structure these relationships as follows:

a). Post Type "User Profiles":
The main post type that will act as an anchor to link each registered user on the website, with other post types. We'll need this, as a post relationship can only be created between two post types and not directly between a post type and a user.

Here is a useful guide on this topic:
https://toolset.com/documentation/post-relationships/how-to-create-custom-searches-and-relationships-for-users/

Note: If your goal is to segregate the website's users and the contributors, you can use two separate post types, i.e. "User Profiles" and "Contributor Profiles". The general idea to connect those users with post types will remain the same.

b). Post Type "Superstacks":
You can continue using this post type to store stack packages, it can have a one-to-many relationship with the "Stack Contributions" post type.
( as one superstack can have many stack contributions )

c). Post Type "Stack Contributions":
You can continue storing each stack item in this post type and as mentioned above, the post relationship will determine which superstack it belongs to.

d). Post Type "Redeem Pages":
I understand these posts represent the sales page for each superstack, so you can create a one-to-one relationship between "Superstacks" and the "Redeem Pages".
( if your goal is to only allow one sales page to link to one superstack and vice versa )

2. Post relationship - connections:

Usually, Toolset Forms are used to connect/disconnect posts (which belongs to post types which are already in a relationship), on the front-end:
https://toolset.com/documentation/post-relationships/how-to-build-front-end-forms-for-connecting-posts/

But in your case, you're using third-party form and checkout process to allow users to buy these superstacks. This means that when a user pays for a certain supertack, you'll need to connect that "Superstacks" post to that user's "User Profiles" post, which would represent that this user is authorized to access to this superstack.

This can be achieved using the "toolset_connect_posts" function from the Toolset Relationship API:
( ref: https://toolset.com/documentation/customizing-sites-using-php/post-relationships-api/#toolset_connect_posts )

You can consult the documentation or support of your checkout plugin to know about a hook that can be used to fire a certain function after every successful checkout/purchase.

3. Content Protection:

Again, in usual Toolset based website's setup, the Toolset Access plugin is used for controlling content's access:
https://toolset.com/documentation/user-guides/setting-access-control/
https://toolset.com/documentation/user-guides/access-control/limiting-read-access-specific-content/
https://toolset.com/documentation/user-guides/access-control/access-control-texts-inside-page-content/

But since your requirement involves, purchased package based access restriction, you can use a slightly different approach.

Basically you'll need to check:
- if the current user's "User Profiles" post is connected to a particular "Superstacks" post or not.
-- If it is connected then that user should be allowed to access this superstack (and it's components).
-- if not, then this user will have to purchase this superstack first.

For this purpose, nested post views and conditional output features can be used and protected content can be wrapped within those conditional checks.

Post Views:
https://toolset.com/documentation/getting-started-with-toolset/create-and-display-custom-lists-of-content/

Showing related posts:
https://toolset.com/documentation/post-relationships/how-to-display-related-posts-with-toolset/

Conditional output:
https://toolset.com/documentation/user-guides/conditional-html-output-in-views/

Note: this last part about the conditional check using the views can sound a bit complicated, but once that data elements and post relationships are in place, this shouldn't be very difficult.
( I'm not going into more details on this particular point in this ticket purposefully, to keeps things simple )

What important is that this is achievable, and once the rest of the set up is complete, you can open a new ticket, if you're having any challenge in accomplishing these conditional checks.

4. Custom Fields:

Your observation is correct about the existing custom fields and there is an option available to let Toolset take control over them:
https://toolset.com/documentation/user-guides/custom-content/convert-existing-custom-types-and-fields-to-types-control/

It is important to note however that, this will work only for simple text-based fields as other custom field plugins can store complex fields ( e.g. Multi-line, select, radio, checkboxes, image/file etc), in a different format/syntax than Toolset.

In case a large amount of custom fields data is involved and manually re-entry is not an option, you can keep it stored in those existing fields. You'll still be able to show that data in views, using either that plugin's own methods or through direct PHP code. But you won't be able to use those fields for view's operations like search filters, sorting etc.

I hope these findings will help and please let me know if any point is not clear.

regards,
Waqar

#1451853

Hello Waqar!

Sorry for spending days to get back on this one. I have a lot to do and are juggling 3 jobs right now. I will follow-up here with a few more comments and questions. But I think I will do this with video, again.

But I will do a quick written recap here on a few things.

Members/customers
They want to continue using Memberpress to control access to the site and its Stacks. Each Superstack with its "sub-post type listed with all the products will belong to a Memberpress membership. When they log in, they will see the page with the Stacks they have access to.

Question: Listing the Stacks post-type using Toolset, users should still only be able to list posts they have a membership for?

I don't think we need to use a post-type for User profiles as you mentioned.

Working with design using Toolset

hidden link