As stramm suggested your 1st question isn't related to this plugin but I'm going to answer it here anyway !
And here is your 1st question's answer ,
You can put user's real name to $USER_DATA array but it needs some core mod.
lets try this ,
- Edit {gallery_root}/bridge/coppermine.inc.php
go to line #83 (after user_group's field name definition ) and add code below to field array
'realname' => 'user_profile1', // name of 'real_name' field in users table
You are done with coppermine.inc.php , save and close !
- Edit {gallery_root}/bridge/udb_base.inc.php
go to line #56 and change it from this
$sql = "SELECT u.{$f['user_id']} AS id, u.{$f['username']} AS username, u.{$f['password']} AS password, ug.{$f['usertbl_group_id']} AS group_id ".
to this
$sql = "SELECT u.{$f['user_id']} AS id, u.{$f['username']} AS username, u.{$f['password']} AS password, u.{$f['realname']} AS real_name, ug.{$f['usertbl_group_id']} AS group_id ".
go to line #60 and change it from this
$sql = "SELECT u.{$f['user_id']} AS id, u.{$f['username']} AS username, u.{$f['password']} AS password, u.{$f['usertbl_group_id']}+100 AS group_id ".
to this
$sql = "SELECT u.{$f['user_id']} AS id, u.{$f['username']} AS username, u.{$f['password']} AS password, u.{$f['realname']} AS real_name, u.{$f['usertbl_group_id']}+100 AS group_id ".
go to line #101 and add this
define('USER_RNAME', $USER_DATA['real_name']);
go to line #146 and add this (to load_user_data function )
$USER_DATA['real_name'] = $row['real_name'];
You are done with udb_base.inc.php too,
- Now you just need to add
$USER_DATA['real_name']
or
USER_RNAME
when ever you need user's real name