WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] [Plugin: WP Private Messages] Adding Private messaging to user Profiles (5 posts)

  1. cde010
    Member
    Posted 4 years ago #

    I have user profiles on my WP using Alkivia Open Community:
    http://wordpress.org/extend/plugins/alkivia/

    I added this code to '\wp-content\plugins\alkivia\templates\profile-default.php :

    <a href="<?php _e('http://renewedculture.com/wp-admin/profile.php?page=wp-private-messages/wpu_private_messages.php&wpu=newpm&id=', $text_domain); ?><?php echo $user->ID ?><?php _e('&name=', $text_domain); ?><?php echo $user->user_login ?>">Send <?php echo $user->display_name ?> a Private Message</a>

    This adds:
    "Send 'username' a Private Message"
    link to every profile. When clicked, it takes that user to their "New Private Messages" page and the name of the user who they are messaging will already be in the field! Yes!

    http://wordpress.org/extend/plugins/wp-private-messages/
    Great plugin.
    Carl

  2. jr2swiss
    Member
    Posted 4 years ago #

    Hi Carl,

    Can you tell me specifically where you put the code?

    Thanks,
    David

  3. cde010
    Member
    Posted 4 years ago #

    David, I put my code directly after:

    <?php }
    
    echo $header;
    if ( aoc_is_active('gallery') ) {
        echo aoc_profile_picture($user);
    }
    
    if ( ! empty($author_link) ) { ?>
    	<p style="text-align:center;"><strong><a href="<?php echo $author_link; ?>"><?php _e('View this author\'s posts', $text_domain); ?></a></strong></p>
    <?php } ?>
  4. Trebour
    Member
    Posted 3 years ago #

    Works great thanks for the info, Im working on trying to get the alert when on main blog rather than profile page maybe like a widget or perhaps coded into the main site.

  5. wzshop
    Member
    Posted 3 years ago #

    He guys,

    This really looks great!
    I installed the wp private message plugin and I added the code to my profile page of alkivia. I use alkivia in comination with theme my profile in order to customize the profile page.

    It adds this link: http://www.xxx.nl/v2/wp-admin/profile.php?page=wp-private-messages/wpu_private_messages.php&wpu=newpm&id=3&name=wzshop

    But because of theme my profile the link redirects to http://www.nownet.nl/v2/profile/?page=wp-private-messages/wpu_private_messages.php&wpu=newpm&id=3&name=wzshop

    which means i get a 404. What can/should i do about this?

    Thanks A LOT!! and looking forward to the Trebour extension as well!

Topic Closed

This topic has been closed to new replies.

About this Topic