WordPress.org

Support

Support » Plugins and Hacks » WP-Members: Membership Framework » [Resolved] [Plugin: wp-members] How do I change the page you are directed to

[Resolved] [Plugin: wp-members] How do I change the page you are directed to

Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Author Chad Butler

    @cbutlerjr

    Yes, there is a filter hook for that.

    <?php
    add_filter( 'wpmem_login_redirect', 'my_login_redirect' );
    
    function my_login_redirect()
    {
    	// return the url that the login should redirect to
    	return 'http://yourdomain.com/your-page';
    }
    ?>

    Where do I need to put this filter hook? In which file after which line?

    Theme’s function.php, or you could do this:

    Creating a custom functions plugin for end users

    which is better so it won’t get updated over by Theme/Plugin updates.

    Regards,
    -Brian

    Plugin Author Chad Butler

    @cbutlerjr

    While yes you could do that, I wouldn’t necessarily say that is “better” because it doesn’t address the bigger issue – you should be making all theme customizations (including functions.php) in a child theme for the specific reason that you don’t want theme updates to overwrite your changes.

    WordPress site management best practices

    (But from an ease of use standpoint – a functions plugin file is a good idea of you want everything to be easily transportable across themes.)

    Thanks Chad,

    I use the functions plugin exactly for the ease of using on multiple sites, but with a little effort a Child Theme would probably be just as easy. I’ll have to look into the Child Themes. Regards,

    -Brian

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘[Resolved] [Plugin: wp-members] How do I change the page you are directed to’ is closed to new replies.
Skip to toolbar