function authcache_preprocess in Authenticated User Page Caching (Authcache) 6
Same name and namespace in other branches
- 7.2 authcache.module \authcache_preprocess()
- 7 authcache.module \authcache_preprocess()
Process all template variables
File
- ./
authcache.module, line 480 - Authenticated User Page Caching (and anonymous users, too!)
Code
function authcache_preprocess(&$variables, $hook) {
global $is_page_authcache;
// Define variables for templates files
$variables['is_page_authcache'] = $is_page_authcache;
if ($variables['user']->uid) {
$variables['user_name'] = $is_page_authcache ? '<span class="authcache-user"></span>' : $variables['user']->name;
$variables['user_link'] = $is_page_authcache ? '<a href="" class="authcache-user-link">!username</a>' : l($variables['user']->name, "user", array(
'alias' => TRUE,
));
}
}