function authcache_key in Authenticated User Page Caching (Authcache) 7.2
Generate and return the authcache key for the given account.
See also
hook_authcache_key_properties()
hook_authcache_key_properties_alter()
Related topics
8 calls to authcache_key()
- authcache_backend_test_exit in tests/
authcache_backend_test.module - Implements hook_ext().
- authcache_builtin_cid in modules/
authcache_builtin/ authcache_builtin.module - Return the authcache cache-id for the given path.
- authcache_builtin_test_exit in modules/
authcache_builtin/ tests/ authcache_builtin_test.module - Implements hook_exit().
- authcache_debug_authcache_debug_info in modules/
authcache_debug/ authcache_debug.module - Implements hook_authcache_debug_info().
- authcache_exit in ./
authcache.module - Implements hook_exit().
File
- ./
authcache.module, line 651 - Authenticated User Page Caching (and anonymous users, too!)
Code
function authcache_key() {
global $user;
if ($user->uid) {
// Calculate the key for logged in users from key-properties.
$key = authcache_user_key(authcache_key_properties(), $user->uid == 1);
}
else {
$key = authcache_backend_anonymous_key();
}
return $key;
}