WordPress.org

Ready to get started?Download WordPress

Forums

WP Login Box
Link only instead of login box (4 posts)

  1. Manitoba
    Member
    Posted 1 year ago #

    Hi,
    Thanks for a great plugin.
    Is it possible to only have a link for user not logged in instead of the login box?
    I tryed to remove the box in the code but it was not that a good idea or I did it wrong :(
    Thanks

    http://wordpress.org/extend/plugins/wp-login-box/

  2. Ziv
    Member
    Plugin Author

    Posted 1 year ago #

    Yeah it is possible...though it's not really the point of the plugin.
    I can tell you how to do this, but first let me know how you use wplb.
    Do you use it with the widget, shortcode, or function?

  3. Manitoba
    Member
    Posted 1 year ago #

    Thanks!
    I´m using it as a widget.
    The reason why I would like only links is because I want to place the links on the top bar of my homepage.
    Your plugin works very fine otherwise.

    Actually I found a function to insert php code in a text widget. I will just use it to build the login / logout logic.

    add_filter('widget_text', 'enable_php_code', 99);
    
    function enable_php_code ($text) {
    if (strpos($text, '<' . '?') !== false) {
    ob_start();
    eval('?' . '>' . $text);
    $text = ob_get_contents();
    ob_end_clean();
    }
    return $text;
    }

    Thanks again

  4. Ziv
    Member
    Plugin Author

    Posted 1 year ago #

    Alright, glad you found something that works :)

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic