forum.coppermine-gallery.net

Support => cpg1.4 plugins => cpg1.4.x Support => Older/other versions => cpg1.4 plugin contributions => Topic started by: m@rk on December 26, 2006, 03:23:19 pm

Title: Plugin: Login info
Post by: m@rk on December 26, 2006, 03:23:19 pm
I will attach my plugin here soon  ;)
Title: Plugin: Login info
Post by: m@rk on December 26, 2006, 03:40:05 pm
I wrote a simple plugin:

Login info adds an info line, if you are logged in or not, below the menu on your Coppermine Photo Gallery.
In Admin Mode, an additional link to the Plugin Manager is displayed.
Title: Plugin: Login info // Languages
Post by: m@rk on December 26, 2006, 03:48:40 pm
P.S.: Available languages so far: English, German

Sorry for multiple postings, I don't seem to be allowed to edit my previous posts here?
Title: How to display user_lastvisit !?
Post by: m@rk on December 26, 2006, 04:54:07 pm
Additionally, I'd like to display user_lastvisit, but I can't solve it...
Why doesn't this make any result?:

Code: [Select]
global $CONFIG, $REFERER;

$since= $lang_plugin_login_info['since'] . " ";

$result = cpg_db_query( "SELECT user_lastvisit FROM {$CONFIG['TABLE_USERS']} WHERE user_id = '{USER_ID}' ");

// why doesn't this make any result ???
while ($row = mysql_fetch_array($result)) {
   $tmp= substr($row['user_lastvisit'],11,5);
   $since .= "{$tmp}";
}

Is there a simple way to display user_lastvisit?
Title: Re: Plugin: Login info
Post by: Nibbler on December 26, 2006, 11:16:06 pm
Code: [Select]
$result = cpg_db_query( "SELECT user_lastvisit FROM {$CONFIG['TABLE_USERS']} WHERE user_id = " . USER_ID);
Title: Re: Plugin: Login info
Post by: m@rk on December 27, 2006, 02:33:27 am
Thank you Nibbler !  ::)

So here is v1.3.

Summary:

Login info adds an info line below the menu on your Coppermine Photo Gallery, if you are logged in or not, and time of login.
In Admin Mode, additional links (manage plugins, view logs, check versions, display phpinfo) are displayed.

Available languages so far: English, German
Title: Re: Plugin: Login info
Post by: François Keller on December 27, 2006, 09:52:21 am
Hey M@rk,

Good work
Attached login_info_1_3_1.zip with french.php lang file and a little modif in lang files to display properly in french the négative you are not (vous n'êtes pas) words.
I've modified the codebase.php for this.
Title: Re: Plugin: Login info
Post by: Hardstyle-boy on May 05, 2009, 04:42:42 pm
hello
i have a problem,

sry for my english it is very bad

i have attach a screenshot

what do I need to change, I see the text so as to screenshot
   
the text below and not the middle of it

   
thanks in advance