user_uid_optional_to_arg
modules/user/user.module, строка 1169
- Версии
- 6
user_uid_optional_to_arg($arg)
Возвращает uid текущего пользователя.
Код
<?php
function user_uid_optional_to_arg($arg) {
// Give back the current user uid when called from eg. tracker, aka.
// with an empty arg. Also use the current user uid when called from
// the menu with a % for the current account link.
return empty($arg) || $arg == '%' ? $GLOBALS['user']->uid : $arg;
}
?>
Войдите или зарегистрируйтесь, чтобы получить возможность отправлять комментарии