Would like to display recent purchases in user profile

I'm using a user front-end plugin for editing their profile and I was wondering/hoping there was a shortcode or any way of displaying purchases by the user.

I'm building a site for an MMA company and using PPV I am allowing them to grant access to pages which will display the livestream. It would be extremely helpful if within their user profile they were able to view their recent purchases and links to those video pages.

  • aristath
    • Recruit

    Hello again @Chris,
    The Pay Per View plugin adds the subscriptions to the user profile on the Dashboard. I don't know how the front-end plugin would do that exactly, but this is the line that adds the info to the backend:

    $PayPerView = new PayPerView;
    add_action( 'show_user_profile', array($PayPerView , 'edit_profile') );

    My guess is that you'd have to change the show_user_profile with an action that your plugin uses.

    I hope that helps!

    Cheers,
    Ari.

  • Chris
    • New Recruit

    Thanks for the response.

    I'm not very versed in the development side of wordpress. I use plugins and style them :slight_smile:.

    Is there any php I can add to a page template where it would display the purchase history?

    Thanks

  • aristath
    • Recruit

    Hello there @Chris,
    I'm sorry it took me so long to reply back to you on this thread, I missed your last post!

    Is there any php I can add to a page template where it would display the purchase history?

    I'm afraid not, this is not something that would require just a couple of lines of code, It's a lot more complex than that. You'll have to post a new job on our Jobs Board on https://premium.wpmudev.org/wpmu-jobs/ so that a skilled developer can create that for you!

    Cheers,
    Ari.

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.