| Server IP : 195.130.67.5 / Your IP : 216.73.217.154 Web Server : Microsoft-IIS/10.0 System : Windows NT WEBSERVER1 10.0 build 17763 (Windows Server 2016) i586 User : IUSR ( 0) PHP Version : 7.4.19 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : OFF | Perl : OFF | Python : OFF | Sudo : OFF | Pkexec : OFF Directory : C:/inetpub/wwwroot/business/sites/all/modules/token/tests/ |
Upload File : |
<?php
/**
* @file
* Helper module for token tests.
*/
/**
* Implements hook_exit().
*/
function token_test_exit() {
if ($debug = variable_get('token_page_tokens', array())) {
$debug += array('tokens' => array(), 'data' => array(), 'options' => array());
foreach (array_keys($debug['tokens']) as $token) {
$debug['values'][$token] = token_replace($token, $debug['data'], $debug['options']);
}
variable_set('token_page_tokens', $debug);
}
}
/**
* Implements hook_date_format_types().
*
* @todo Remove when http://drupal.org/node/1173706 is fixed.
*/
function token_test_date_format_types() {
$info['token_test'] = t('Token test date format');
// Explicitly set the variable here as well.
variable_set('date_format_token_test', 'Y');
return $info;
}