User submitted posts that expire when payment lapses

Hello!

We’re looking to build a “Business Directory” using Gravity Forms - but - are not sure the best way go about it from a billing and management perspective.

Ideally the way the system would work is a user would sign up for an account and use Gravity Forms to submit and manage their business listing (I plan to use GravityView for this!) but we would also like it so when the users payment lapses or they cancel their account any entries they had submitted would be removed from the front end listing.

Does anyone have guidance or tips on how to handle this? I was thinking of using WooCommerce Subscriptions or Gravity Plus to handle the subscriptions / payment management I am just not sure how to connect it with the automatic listing removal.

Thank you so much!

I think you can use the Post Expirator plugin for that, to actually handle the expiration.

The trick will be to get the expiration date associated with the post when it is created (if it was a one-year directory listing or something) or, to actually expire it when some action happens (subscription payment fails or account is cancelled.) Whatever plugin you are using the manage the subscription will need to have a hook which runs after the payment fails, or their membership is voided or cancelled. Once you decide on a plugin, you can check for that hook which runs after the subscription ends, then you can expire the post in whatever method the Post Expirator plugin uses.

It can certainly be done but will require tying some systems together with PHP and some built in hooks. None of that actually happens in Gravity Forms (other than the initial post creation.)

Hi Elizabeth,
You can use GravityView’s Advanced Filters (included in the Core + Extensions license) to do this—you will set up a filter on the payment status to check whether the subscription is active. If it isn’t active, it will be hidden from the View—no extra plugins needed!

Thanks for your question :slight_smile:

Zack

3 Likes

Elizabeth,

I’m working on something very similar and I wondered if I could pick your brain about a few aspects of this setup? Let me know…

Thank you!

– Rachel

Hey Rachel –

We ended up going with Zack’s suggestion:

We’ve built quite a few things in the past using Gravity View - so - this was a pretty easy thing for us to do and required just a basic filter.

I’d strongly recommend it - it’s a little pricey - but a great plugin that I’ve found to be worth it over the years. :blush:

Hope that helps!

Hi Elizabeth,

Oh, yes, I’m using GravityView – because it’s the best thing ever. :slight_smile:

A couple of years ago, I built some business directories using GravityView for one of my clients.

Now my client wants to add a couple of fairly obvious functions that we didn’t get to before: (1) automated emails to him and to the directory listing owners when the listings are about to expire; (2) a renewal form to pay for another year (he doesn’t want to have automatic subscription payments).

So currently I’m working on doing that by integrating the Gravity Forms directory listing submission form with Wishlist Member.Yesterday I added Gravity Wishlist to hook that up.

I think I’ve got most of the details sorted out yesterday, but if not, would it be okay if I asked you a couple of questions?

Sure! Ask away!

We personally set it up with WooCommerce + WooCommerce Subscriptions - but - I might be able to help.

© 2008 - 2019. Gravity Forms is a project by Rocketgenius Inc.