latest stable versions: v150827 (changelog)

Old Forums (READ-ONLY): The community now lives at WP Sharks™. If you have an s2Member® Pro question, please use our new Support System.

RIght approach for Custom Capabilities

Home Forums Community Forum RIght approach for Custom Capabilities

This topic contains 1 reply, has 2 voices. Last updated by  Cristián Lávaque 3 years, 10 months ago.

Topic Author Topic
Posted: Saturday Mar 2nd, 2013 at 11:25 am #43626
david
Username: solar

Want to share what I am doing and see if anyone do it differently.

I have many posts and CPT in a wordpress site. I have a free subscription and a payed subscription. According to them in the single.php view the user can see partial or whole content.
Then I have another part of my template with other things :

  • other paragraphs
  • and post attachments (like ZIP,PDF)

which I want to make available only with a separate purchase. Maybe users won’t have to be Members yet to buy these informations, but is still to be decided.

My approach is to dinamically set a Custom capability and his related Pro Form, using for the CC name the ID of the POST (which will be surely unique).
Here is the code:

Some free content

    
    Some premium content for all Level 1 Members.

    
        Display text and attachments as well.
        
    
    

    Some public content and a Paypal button (shortcode below)

Then the Paypal Pro form would be:

I have not tested yet, anybody thinks it is well made?
Jason Caldwell, your opinion is welcome!

List Of Topic Replies

Viewing 1 replies (of 1 total)
Author Replies
Author Replies
Posted: Tuesday Mar 5th, 2013 at 9:10 am #43771

Hi David.

You put [hilite mono]the_ID()[/hilite] inside single quotes, so it’s a string, not a function call.

Viewing 1 replies (of 1 total)

This topic is closed to new replies. Topics with no replies for 2 weeks are closed automatically.

Old Forums (READ-ONLY): The community now lives at WP Sharks™. If you have an s2Member® Pro question, please use our new Support System.

Contacting s2Member: Please use our Support Center for bug reports, pre-sale questions & technical assistance.