1

I'm looking to give members the ability to buy photography specific to them.

I was wondering if there is a way in Cartthrob for me to display certain products to certain members via playa field containing a member? OR (this might be even better) drop files in a P&T Assets directory and assign that directory to a specific Member? The photos (product) will always be the same price across the board.

I guess I'm kind of looking to do both (for 2 different projects) - One with the ability for specific members to buy specific photos and another where specific members can see specific products only.

Any thoughts?

Thanks!

Best,

Jon

1

You can easily assign entries to a specific member by making them the author of the entry then using the author_id parameter in your channel entries tag. Alternatively you can use a plugin such as VZ Member or VMG Chosen Member to select either a single or multiple members that you could then use a conditional in your template to show only entires which they have been selected. Or there is another add-on called Entry Access that allows you to grant access on a per entry basis. One of the nice things about Entry access is that you can preselect members or member groups that you want to have access to all entries by default (handy for admins to see the entries)

| improve this answer | |
  • Hey Justin - The Entry Access sounds awesome. However, can this be used with in conjunction with cartthrob, entry/product specific? Selecting multiple members to access an entry/product? – Jon Nixon Mar 10 '13 at 20:30
  • CartThrob just extends channel entries in EE so I do not see why it would cause problems with Entry Access. I have a copy of both so I can do a test for you when I get back home. – Justin Long Mar 10 '13 at 20:51
  • I did a quick little test and it worked without a problem – Justin Long Mar 10 '13 at 21:52
0

You don't mention whether you're using an addon that stores member profiles as channel entries, but with Profile:Edit and Playa it's relatively trivial to display products related to (presumably?) the currently logged in member. If you tick the box to have Profile:Edit store its data as global variables you can use {profile:entry_id} as the value for any Playa or channel:entries tag parameters.

Otherwise, setting the member as the author of the entry as Justin suggests would also be a good approach if you only require one member per product.

The Assets approach may be possible but could be a bit limiting in future - probably best to keep everything as channel entries (the products themselves can still use file/assets fields ).

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.