Example #1
0
 /**
  *
  */
 public static function fix_permissionsHelp()
 {
     return _t("CollectiveAccess must have both read and write access to the temporary storage directory (app/tmp), media directory (media) and HTMLPurifier definition cache (app/lib/core/Parsers/htmlpurifier/standalone/HTMLPurifier/DefinitionCache). A run-time error will be displayed if any of these locations is not accessible to the application. To change these permissions to allow CollectiveAccess to run normally run this command while logged in with administrative/root privileges. You are currently logged in as %1 (uid %2). You can specify which user will be given ownership of the directories using the --user option. If you do not specify a user, the web server user for your server will be automatically determined and used.", caGetProcessUserName(), caGetProcessUserID());
 }
Example #2
0
/**
 *
 */
function caGetProcessUserName()
{
    if (function_exists("posix_getpwuid")) {
        if (is_array($va_user = posix_getpwuid(caGetProcessUserID()))) {
            return $va_user['name'];
        }
    }
    return null;
}