WordPress.org

Ready to get started?Download WordPress

Forums

Widget Logic
Logic to appear widget at current user's profile page only (5 posts)

  1. frostfairs
    Member
    Posted 1 year ago #

    I am afraid if is there any logic which 'll be effective to show the widget on the profile of current and logged in user only? like in facebook, the left sidebar in facebook is visible at every current user's home page only.

    http://wordpress.org/extend/plugins/widget-logic/

  2. alanft
    Member
    Plugin Author

    Posted 1 year ago #

    !is_user_logged_in() -- shown when a user is not logged in

    comes from

    http://wordpress.org/extend/plugins/widget-logic/other_notes/

    you could use that without the ! at the beginning

  3. frostfairs
    Member
    Posted 1 year ago #

    This 'll work and the widget 'll be visible when the user is logged in.
    But is there any way that , this may be visible on the sidebar of the user's profile?
    when the logged in user click on his profile link, he/she found the widget there only, on the sidebar reside his profile?

  4. alanft
    Member
    Plugin Author

    Posted 1 year ago #

    Not on the user profile you see at …wordpress/wp-admin/profile.php , as that's in the wp-admin interface which I don't believe can have a widget-y sidebar.

    But you could do it on their post page …/author/user_name using code from this page

    http://codex.wordpress.org/Function_Reference/get_currentuserinfo

    which suggests that

    global $current_user; get_currentuserinfo(); return is_author($current_user->user_login);

    might work

  5. frostfairs
    Member
    Posted 1 year ago #

    Am actually talking with the buddypress' perspective. When you have buddypress i think there is no more need for the user, to access the admin interface panel but within the front end of the site, it is possible to change the settings regarding the profile.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags

No tags yet.