WordPress.org

Ready to get started?Download WordPress

Forums

WP-Members
[resolved] Change the 'Begin using this site' link (2 posts)

  1. KathleenH
    Member
    Posted 2 years ago #

    Hi there! I have a 'Register' page and was wondering if I could change a link on it. It gives the option to 'Begin searching this site' which is linked to the homepage. I know that for most people this is ideal, but in my case I'm using WP-Members for added functionality for a forum. So what I'd looooove to do is change that link to point to the forum page. Is that possible?

    Thanks Chad - brilliant plugin! Lovin' it!!

    http://wordpress.org/extend/plugins/wp-members/

  2. Chad Butler
    Member
    Plugin Author

    Posted 2 years ago #

    Yes, there is a filter hook for that: wpmem_register_links.

    The filter passes the default output as a string. Adding a filter to your functions.php, you can alter this by adding to it, drop it and return something completely different, or using something like str_replace, replace a specific piece of it.

    Here's an example:

    add_filter( 'wpmem_register_links', 'my_register_links' );
    function my_register_links( $string ) {
    
    	// Original link output comes in as a $string.
    	// You can add to it before or after, or drop it altogether.
    
    	$string = "<p>I put this before the original links</p>" . $string;
    	$string = $string . "<p>This is extra stuff I added after...</p>";
    
    	return $string;
    
    }

    A list of available hooks is in the Users Guide found at http://butlerblog.com/wp-members

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags