You are here

function hook_authcache_p13n_client_fallback_alter in Authenticated User Page Caching (Authcache) 7.2

Change the fallback markup inserted when no client is available.

Parameters

string &$markup: The markup replacing the rendered fragment.

string $method: The fallback method, e.g., 'hide', 'cancel'

array $context: An associative array containing the following key-value pairs:

  • type: One of 'fragment', 'setting', 'assembly' or 'partial'.
  • id: The fragment-, setting-, assembly-, partial-identifier.
  • param: The parameter for this instance.
  • clients: An array of weighted client definitions supplied to the theming-function.
2 functions implement hook_authcache_p13n_client_fallback_alter()

Note: this list is generated by pattern matching, so it may include some functions that are not actually implementations of this hook.

authcache_p13n_authcache_p13n_client_fallback_alter in modules/authcache_p13n/authcache_p13n.module
Implements hook_authcache_p13n_client_fallback_alter().
authcache_p13n_test_authcache_p13n_client_fallback_alter in modules/authcache_p13n/tests/authcache_p13n_test.module
Implements hook_authcache_p13n_client_fallback_alter().
4 invocations of hook_authcache_p13n_client_fallback_alter()
theme_authcache_p13n_assembly in modules/authcache_p13n/authcache_p13n.module
Theme a placeholder for a personalized assembly.
theme_authcache_p13n_fragment in modules/authcache_p13n/authcache_p13n.module
Theme a placeholder for a personalized fragment.
theme_authcache_p13n_partial in modules/authcache_p13n/authcache_p13n.module
Theme a placeholder for a part of an assembly.
theme_authcache_p13n_setting in modules/authcache_p13n/authcache_p13n.module
Theme a placeholder for a personalized setting.

File

modules/authcache_p13n/authcache_p13n.api.php, line 269
Documentation for hooks provided by the authcache personalization module.

Code

function hook_authcache_p13n_client_fallback_alter(&$markup, $method, $context) {
  switch ($method) {
    case 'cancel':
      authcache_cancel(t('No client for %type %id', array(
        '%type' => $context['type'],
        '%id' => $context['id'],
      )));
      break;
  }
}