You are here

function theme_authcache_p13n_assembly__authcache_ajax in Authenticated User Page Caching (Authcache) 7.2

Theme function for groups of fragments loaded in only one Ajax call.

File

modules/authcache_ajax/authcache_ajax.module, line 96
Inject personalized fragments into cached pages using Ajax calls.

Code

function theme_authcache_p13n_assembly__authcache_ajax($variables) {
  $url = $variables['url'];
  $class = $variables['class'];
  if ($url && $class) {
    drupal_add_js(drupal_get_path('module', 'authcache_p13n') . '/authcache_p13n.js');
    drupal_add_js(drupal_get_path('module', 'authcache_ajax') . '/authcache_ajax.js');
    drupal_add_js(array(
      'authcacheP13nAjaxAssemblies' => array(
        'span.' . $class => url($url['path'], $url['options']),
      ),
    ), 'setting');
    return '';
  }
}