aboutsummaryrefslogtreecommitdiff
path: root/h-source/Application/Models/UsersModel.php
diff options
context:
space:
mode:
authorAntonio Gallo <tonicucoz@gmail.com>2011-02-15 11:45:38 +0000
committerAntonio Gallo <tonicucoz@gmail.com>2011-02-15 11:45:38 +0000
commitd85570c9946aef61d8d935d9f50169215338d665 (patch)
tree80ff5e94178d9aa09bebfc6b897251078836cdd5 /h-source/Application/Models/UsersModel.php
parent8c287999487883a54271ae5e91bbb79b4fd15826 (diff)
improved wiki
Diffstat (limited to 'h-source/Application/Models/UsersModel.php')
-rwxr-xr-xh-source/Application/Models/UsersModel.php18
1 files changed, 18 insertions, 0 deletions
diff --git a/h-source/Application/Models/UsersModel.php b/h-source/Application/Models/UsersModel.php
index a7c3845..fe72ce7 100755
--- a/h-source/Application/Models/UsersModel.php
+++ b/h-source/Application/Models/UsersModel.php
@@ -88,6 +88,24 @@ class UsersModel extends Model_Map
}
}
+ public function getLinkToUser($user)
+ {
+ if (strstr($user,'__'))
+ {
+ return str_replace('__',null,$user);
+ }
+ else
+ {
+ return "<a href='http://".DOMAIN_NAME."/meet/user/".Lang::$current."/$user'>$user</a>";
+ }
+ }
+
+ public function getLinkToUserFromId($id_user = 0)
+ {
+ $clean['id_user'] = (int)$id_user;
+ return $this->getLinkToUser($this->getUser($clean['id_user']));
+ }
+
//get the user id from the username
public function getUserId($username = '')
{