Gossamer Forum
Quote Reply
Get COmmunity username
Hi,

I am trying us fetch the Community username (comm_username) based on the Forum ID using a global.

I used the following based on username in Links - can anyone help re-writing this so I get the username based on ID.

Code:
sub {
my $user = shift;
return unless $user;
my $cfg = Links::Plugins->get_plugin_user_cfg('Auth_Community');
lib->import($cfg->{community_private} . '/lib');
require Community;
Community->import(qw/comm_init comm_get_profile/);
comm_init($cfg->{community_private});
return comm_get_profile($user);
}

Any help would be appreciated

Klaus

http://www.ameinfo.com
Quote Reply
Re: [klauslovgreen] Get COmmunity username In reply to
You can use:

<%Plugins::GForum::Auth_Community::get_profile%>

and it will set comm_* for the currently logged in user.

Cheers,

Alex
--
Gossamer Threads Inc.
Quote Reply
Re: [Alex] Get COmmunity username In reply to
That was easy - thanks :-)

Now the other way around - how can i get the Message bit into Community?

ie.
Messages
1 NEW

Cheers
Klaus

http://www.ameinfo.com