"Pay to Blog" - suspending websites who haven't paid

Hey,
Great plugins guys!

Just a question about Pay to Blog. I'm setting up a multi-site for users to subscribe to the service, to have their own complete Wordpress website.

As it is, if a user doesn't pay their account, they don't have access to the backend until they subscribe again. But I need the frontend website to go down too (as in perhaps it gets redirected to a static - 'This user hasn't paid their account').

How can I do this??

Matt

  • Philip John
    • DEV MAN’s Apprentice

    Hey Matt!

    Great plugins guys!

    Thanks so much, and welcome to WPMU DEV! :smiley:

    I need the frontend website to go down too (as in perhaps it gets redirected to a static - 'This user hasn't paid their account

    Hmm interesting! I believe this would be possible, but would require some custom coding. Something like this should work;

    $blog_expire = get_option('blog_expire');
    if ( time() > $blog_expire ) {
      /* do something */
    }

    You will need to place that code either in a plugin that uses a front-end only hook or place it in your theme at the top of the header.php file.

    Replace the 'do something' comment with code that returns a 404 error or just die() with a nice message.

    Phil

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.