本文整理汇总了PHP中drupal_set_html_head函数的典型用法代码示例。如果您正苦于以下问题:PHP drupal_set_html_head函数的具体用法?PHP drupal_set_html_head怎么用?PHP drupal_set_html_head使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了drupal_set_html_head函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: nub_core_preprocess_page
/**
* Implementation of preprocess_page().
*/
function nub_core_preprocess_page(&$vars)
{
$html_attr = array();
$html_attr['lang'] = $vars['language']->language;
$html_attr['dir'] = $vars['language']->dir;
$vars['html_attr'] = array_filter($html_attr);
$body_attr = array();
$body_attr['class'] = $vars['body_classes'];
$vars['body_attr'] = array_filter($body_attr);
// Theme primary and secondary menu.
$vars['primary_links'] = !empty($vars['primary_links']) ? menu_tree(variable_get('menu_primary_links_source', 'primary-links')) : "";
$vars['secondary_links'] = !empty($vars['secondary_links']) ? theme('links', $vars['secondary_links'], array('class' => 'menu')) : "";
// Split primary and secondary local tasks
$vars['tabs_primary'] = theme('menu_local_tasks', 'primary');
$vars['tabs_secondary'] = theme('menu_local_tasks', 'secondary');
// Branding
$logo_path = ltrim($vars['logo'], '/');
$vars['logo_linked'] = file_exists($logo_path) ? l(theme('image', $logo_path, $vars['site_name'] . ' logo'), '<front>', array('html' => TRUE, 'attributes' => array('class' => 'site-logo', 'title' => 'Back to home'))) : '';
$vars['site_name_linked'] = l($vars['site_name'], '<front>', array('attributes' => array('title' => 'Back to home')));
// Skip navigation links (508).
$vars['skip_nav'] = '<a id="skip-nav" class="anchorLink" href="#main">' . t('Skip navigation') . '</a>';
// Back to top.
$vars['back_to_top'] = '<a id="back-to-top" class="anchorLink" href="#header">' . t('↑ Back to top') . '</a>';
// Copyright text
$vars['copyright'] = "© " . date("Y") . " " . $vars['site_name'] . '.';
// Remove duplicate content-type header -- see http://drupal.org/node/451304
$vars['head'] = drupal_set_html_head();
}
示例2: GetLink
/**
* UI helper methods
*/
public function GetLink($link_key, $token, $returnURL, $is_iframe = FALSE)
{
$links = array('profile_view' => 'Profile/ViewProfile.aspx', 'profile_edit' => 'Profile/EditProfile.aspx', 'profile_register' => 'Profile/CreateNewUser.aspx', 'profile_password' => 'LogIn/RetrievePassword.aspx', 'iframe_js' => 'javascripts/iframe.js');
if (array_key_exists($link_key, $links)) {
$format = $this->ui_root . $links[$link_key];
$query = $params = array();
if (!empty($token)) {
$query[] = 'Token=%s';
$params[] = $token;
}
if (!empty($returnURL)) {
$query[] = 'ReturnPage=%s';
$params[] = $returnURL;
}
if (!empty($query)) {
$format .= '?' . implode('&', $query);
}
$path = vsprintf($format, $params);
if ($is_iframe) {
drupal_set_html_head('<script type="text/javascript" src="' . $this->ui_root . $links['iframe_js'] . '"></script>');
return '<iframe src="' . $path . '" isgwebsite="1" name="ISGwebContainer" id="ISGwebContainer" marginwidth="1" marginheight="0" frameborder="0" vspace="0" hspace="0" scrolling="no" style="width:100%; height:800px;"></iframe>';
}
return $path;
}
return NULL;
}
示例3: instant_indicia_preprocess_page
function instant_indicia_preprocess_page(&$variables)
{
// Check path to determine widget pages
$pathargs = explode('/', drupal_get_path_alias($_GET['q']));
if ($pathargs[0] == 'external' || !empty($_GET['external']) && $_GET['external'] === 't') {
// Use template: page__widgets
$variables['template_file'] = 'page-iframe';
} elseif ($pathargs[0] == 'popup' || !empty($_GET['popup']) && $_GET['popup'] === 't') {
// Use template: page__widgets
$variables['template_file'] = 'page-popup';
}
drupal_set_html_head('<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">');
$variables['head'] = drupal_get_html_head();
}
示例4: addJavascriptToHeader
public function addJavascriptToHeader()
{
$js = '<script type="text/javascript" src="https://www.google.com/jsapi"></script>';
$js .= '<script>
google.load("visualization", "1", {packages:["corechart"]});
google.setOnLoadCallback(drawChart);
function drawChart() {
var data = ' . json_encode($this->data) . ';
var titles = ' . json_encode($this->titles) . ';
var i;
for ( i in data ) {
var options = {
title: titles[i]
};
var chart = new google.visualization.LineChart(document.getElementById(i));
var d = google.visualization.arrayToDataTable(data[i]);
chart.draw(d, options);
}
}
';
$js .= '</script>';
drupal_set_html_head($js);
}
示例5: drupal_set_html_head
<?php
$my_rss_data = '<link rel="alternate" type="application/rss+xml" title="RSS - ' . $profile->profile_title . '" href="/blog/' . $profile->uid . '/feed" />';
drupal_set_html_head($my_rss_data);
global $user;
?>
<h1>
<?php
if ($profile->profile_title) {
drupal_set_title($profile->profile_title);
} else {
$profile->profile_title = $profile->name . '\'s paddling profile';
}
print $profile->profile_title;
?>
</h1>
<?php
if ($profile->profile_tagline) {
print '<h3>' . $profile->profile_tagline . '</h3>';
}
?>
<?php
if ($profile->uid == $user->uid) {
?>
<p>(<em><a href="/node/add/blog" title="Write a blog entry!">Add a blog post</a></em>)</p>
<?php
}
示例6: drupal_set_html_head
<?php
//}
?>
</ul>
<?php
}
?>
<div id="details"><div class="tabs-in-wrapper">
<?php
print $node->content['body']['#value'];
?>
<?php
//dsm($node);
if ($appid = variable_get('facebook_comments_appid', '733615273329934')) {
$element = '<meta property="fb:app_id" content="' . $appid . '" />';
drupal_set_html_head($element);
}
global $base_url;
$fb_url = $base_url . '/' . drupal_get_path_alias($_GET['q']);
?>
<div id="fb-root"></div>
<script>(function(d, s, id) {
var js, fjs = d.getElementsByTagName(s)[0];
if (d.getElementById(id)) return;
js = d.createElement(s); js.id = id;
js.src = "//connect.facebook.net/en_US/sdk.js#xfbml=1&version=v2.4";
fjs.parentNode.insertBefore(js, fjs);
}(document, 'script', 'facebook-jssdk'));</script>
<div class="fb-comments" data-href="<?php
echo $fb_url;
?>
示例7: array
<?php
/*
* Initialize theme settings
*/
if (is_null(theme_get_setting('mies_unit'))) {
// <-- change this line
global $theme_key;
// Save default theme settings
$defaults = array('mies_collumns_number' => 8, 'mies_collumn_width' => 112, 'mies_interspace_width' => 10, 'mies_unit' => "px");
variable_set(str_replace('/', '_', 'theme_' . $theme_key . '_settings'), array_merge($defaults, theme_get_settings($theme_key)));
// Force refresh of Drupal internals
theme_get_setting('', TRUE);
}
drupal_set_html_head(' ' . mies_display_grid_css());
//drupal_set_html_head(' '.mies_display_grid());
//drupal_add_css(drupal_get_path('theme', 'mies')."/yaml/core.css", 'theme');
//drupal_rebuild_theme_registry();
function mies_theme()
{
return array('links' => array('arguments' => array('links' => NULL, 'attributes' => array('class' => 'links'))), 'comment_block' => array('arguments' => ''), 'comment_wrapper' => array('arguments' => array('content' => NULL, 'node' => NULL)), 'recent_bookmarks_block' => array('arguments' => array('items' => array())));
}
function mies_links($links, $attributes = array('class' => 'links'))
{
global $teaser;
//dprint_r($links);
// Unset the "node read more" link.
if (isset($links["node_read_more"])) {
$readmore = $links["node_read_more"];
unset($links["node_read_more"]);
//array_push($links,$readmore);
示例8: drupal_set_html_head
$video = $locum->csv_parser($locum_config['format_groups']['video']);
$music = $locum->csv_parser($locum_config['format_groups']['music']);
if (in_array($item['mat_code'], $books)) {
drupal_set_html_head('<meta property="og:type" content="book" />');
} else {
if (in_array($item['mat_code'], $music)) {
drupal_set_html_head('<meta property="og:type" content="album" />');
} else {
if (in_array($item['mat_code'], $video)) {
if (stristr('DVD TV', $item['callnum'])) {
drupal_set_html_head('<meta property="og:type" content="tv_show" />');
} else {
drupal_set_html_head('<meta property="og:type" content="movie" />');
}
} else {
drupal_set_html_head('<meta property="og:type" content="product" />');
}
}
}
$useriplabels = ipmap_labels();
if ($item['trailers']) {
if ($item['trailers'][0]['type'] == 'trailer') {
$trailer_url = $item['trailers'][0]['url'];
if ($item['trailers'][0]['image']) {
$trailer_image = $item['trailers'][0]['image'];
}
if ($item['trailers'][0]['cached'] && in_array('internal', $useriplabels)) {
$trailer_url = 'http://media.aadl.org/trailers/' . $item['bnum'] . '.mp4';
}
}
}
示例9: update_progress_page_nojs
/**
* Perform updates for the non-JS version and return the status page.
*/
function update_progress_page_nojs()
{
drupal_set_title('Updating');
$new_op = 'do_update';
if ($_SERVER['REQUEST_METHOD'] == 'GET') {
// Error handling: if PHP dies, it will output whatever is in the output
// buffer, followed by the error message.
ob_start();
$fallback = '<p class="error">An unrecoverable error has occurred. You can find the error message below. It is advised to copy it to the clipboard for reference. Please continue to the <a href="cvs_to_versioncontrol_project_update.php?op=error">update summary</a>.</p>';
print theme('maintenance_page', $fallback, FALSE, TRUE);
list($percentage, $message) = update_do_updates();
if ($percentage == 100) {
$new_op = 'finished';
}
// Updates successful; remove fallback
ob_end_clean();
} else {
// Abort the update if the necessary modules aren't installed.
if (!module_exists('versioncontrol') || !module_exists('versioncontrol_project') || !module_exists('cvs')) {
print update_finished_page(FALSE);
return NULL;
}
// This is the first page so return some output immediately.
$percentage = 0;
$message = 'Starting updates';
}
drupal_set_html_head('<meta http-equiv="Refresh" content="0; URL=cvs_to_versioncontrol_project_update.php?op=' . $new_op . '">');
$output = theme('progress_bar', $percentage, $message);
$output .= '<p>Updating your site will take a few seconds.</p>';
// Note: do not output drupal_set_message()s until the summary page.
print theme('maintenance_page', $output, FALSE);
return NULL;
}
示例10: phptemplate_geomap
/**
* Override default geomap theming
* Surround with <div> for proper boxing
* Use modified jquery
*
* The Javascript will use this div to render tha map.
* This will be empty if no geo microformats exist on the current page.
*
* @param $delta If more than one map needs to be displayed add an identifier
* @ingroup themeable
* @return Map div
*/
function phptemplate_geomap($delta = '')
{
if ($google_key = variable_get('googlemaps_key', '')) {
drupal_set_html_head('<script type="text/javascript" src="http://maps.google.com/maps?file=api&t=h&z=7&v=2&key=' . $google_key . '" ></script>');
drupal_add_js(path_to_theme() . '/jquery.nabuur.googlemaps.js', 'theme');
drupal_add_css(drupal_get_path('module', 'geomap') . '/geomap.css', 'module');
//TODO: Allow a different ID one day (use delta)
$mapid = 'map';
$output .= '<div class="map-box"><div id="' . $mapid . '" class="googlemap googlemap-' . $delta . '"></div></div>';
$GLOBALS['geomap'] = true;
} else {
if (user_access('administer site configuration')) {
$output = l(t('No geomap googleapi key'), 'admin/settings/geomap');
}
}
return $output;
}
示例11: import_progress_page_nojs
/**
* Perform imports for the non-JS version and return the status page.
*/
function import_progress_page_nojs()
{
drupal_set_title('Importing');
$new_op = 'do_import_nojs';
if ($_SERVER['REQUEST_METHOD'] == 'GET') {
// Error handling: if PHP dies, it will output whatever is in the output
// buffer, followed by the error message.
ob_start();
$fallback = '<p class="error">An unrecoverable error has occurred. You can find the error message below. It is advised to copy it to the clipboard for reference. Please continue to the <a href="merci_import.php?op=error">import summary</a>.</p>';
print theme('maintenance_page', $fallback, FALSE, TRUE);
list($percentage, $message) = import_do_imports();
if ($percentage == 100) {
$new_op = 'finished';
}
// Imports successful; remove fallback
ob_end_clean();
} else {
// This is the first page so return some output immediately.
$percentage = 0;
$message = 'Starting import';
}
drupal_set_html_head('<meta http-equiv="Refresh" content="0; URL=merci_import.php?op=' . $new_op . '">');
$output = theme('progress_bar', $percentage, $message);
$output .= '<p>Importing the data will take a few seconds.</p>';
// Note: do not output drupal_set_message()s until the summary page.
print theme('maintenance_page', $output, FALSE);
return NULL;
}
示例12: drupal_add_js
<?php
/**
** moo fx pack
**/
drupal_add_js(path_to_theme() . '/scripts/prototype.lite.js');
drupal_add_js(path_to_theme() . '/scripts/moo.fx.js');
drupal_add_js(path_to_theme() . '/scripts/moo.fx.pack.js');
drupal_add_js(path_to_theme() . '/scripts/site.js');
drupal_add_js(path_to_theme() . '/scripts/tooltip.js');
drupal_set_html_head('<!--[if lt IE 7]>
<script defer type="text/javascript" src="' . base_path() . path_to_theme() . '/scripts/png.js"></script>
<style type="text/css" media="all">@import "' . base_path() . path_to_theme() . '/ie.css";</style>
<![endif]-->');
/**
** set some styles
**/
drupal_set_html_head('<style type="text/css" media="all">@import "' . base_path() . path_to_theme() . '/style.css";</style>');
示例13: unset
<?php
/**
* This is a bunch of custom form code to show a much prettier story create form within the group
* Extensive use of suggestions at:
* http://drupal.org/node/601646
**/
// remove some other buttons
unset($form['buttons']['preview']);
// include the libraries for geocoding from the single address text input field
drupal_set_html_head('<script type="text/javascript" src="http://maps.google.com/maps/api/js?sensor=false"></script>');
jquery_ui_add(array("jquery.ui.core", "jquery.ui.widget", "jquery.ui.position", "jquery.ui.autocomplete"));
drupal_add_js(drupal_get_path('theme', 'cdh_juarez') . '/js/location-autocomplete.js');
?>
<div class="row cdhj-submit-form">
<div class="sixcol">
<?php
print drupal_render($form['title']);
?>
<?php
print drupal_render($form['body_field']);
?>
<div class="form-item">
<?php
print drupal_render($form['field_image']);
?>
示例14: html5_base_preprocess_page
function html5_base_preprocess_page(&$vars, $hook)
{
// charrset
// Set charset to html5 method
$vars['head'] = str_replace('<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />', '<meta charset="utf-8" />', $vars['head']);
// Modernizr
// Add "no-js" class to <html> if Modernizr is included
if (theme_get_setting('html5_base_modernizr')) {
$vars['modernizr_head'] = 'class="no-js"';
}
// Always force latest IE rendering engine (even in intranet) & Chrome Frame
if (theme_get_setting('html5_base_include_chrome_frame')) {
$vars['head'] = drupal_set_html_head('<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">');
}
// dsm($vars);
// Mobile Viewport Fix
if (theme_get_setting('html5_base_use_mobile_viewport') && strlen(theme_get_setting('html5_base_mobile_viewport')) > 1) {
$vars['head'] = drupal_set_html_head('<meta name="viewport" content="' . theme_get_setting('html5_base_mobile_viewport') . '">');
}
// Don't display empty help from node_help().
if ($vars['help'] == "<div class=\"help\"><p></p>\n</div>") {
$vars['help'] = '';
}
// Classes for body element. Allows advanced theming based on context
// (home page, node of certain type, etc.)
$body_classes = explode(' ', $vars['body_classes']);
if (user_access('administer blocks')) {
$body_classes[] = 'admin';
}
if (theme_get_setting('html5_base_wireframe')) {
$body_classes[] = 'with-wireframes';
// Optionally add the wireframes style.
}
if (!empty($vars['primary_links']) or !empty($vars['secondary_links'])) {
$body_classes[] = 'with-navigation';
}
if (!empty($vars['secondary_links'])) {
$body_classes[] = 'with-secondary';
}
if (module_exists('taxonomy') && isset($vars['node']) && $vars['node']->nid) {
foreach (taxonomy_node_get_terms($vars['node']) as $term) {
$body_classes[] = 'tax-' . eregi_replace('[^a-z0-9]', '-', $term->name);
}
}
if (!$vars['is_front']) {
// Add unique classes for each page and website section
$path = drupal_get_path_alias($_GET['q']);
list($section, ) = explode('/', $path, 2);
$body_classes[] = html5_base_id_safe('page-' . $path);
$body_classes[] = html5_base_id_safe('section-' . $section);
if (arg(0) == 'node') {
if (arg(1) == 'add') {
if ($section == 'node') {
array_pop($body_classes);
// Remove 'section-node'
}
$body_classes[] = 'section-node-add';
// Add 'section-node-add'
} elseif (is_numeric(arg(1)) && (arg(2) == 'edit' || arg(2) == 'delete')) {
if ($section == 'node') {
array_pop($body_classes);
// Remove 'section-node'
}
$body_classes[] = 'section-node-' . arg(2);
// Add 'section-node-edit' or 'section-node-delete'
}
}
}
$vars['layout'] = 'none';
if (!empty($vars['sidebar_first'])) {
$vars['layout'] = 'first';
}
if (!empty($vars['sidebar_second'])) {
$vars['layout'] = $vars['layout'] == 'first' ? 'both' : 'second';
}
// If the layout is 'none', then template_preprocess_page() will already have
// set a 'no-sidebars' class since it won't find a 'left' or 'right' sidebar.
if ($vars['layout'] != 'none') {
// Remove the incorrect 'no-sidebars' class.
if ($index = array_search('no-sidebars', $body_classes)) {
unset($body_classes[$index]);
}
// Set the proper layout body classes.
if ($vars['layout'] == 'both') {
$body_classes[] = 'two-sidebars';
} else {
$body_classes[] = 'one-sidebar';
$body_classes[] = 'sidebar-' . $vars['layout'];
}
}
/* // Check what the user's browser is and add it as a body class
// DEACTIVATED - Only works if page cache is deactivated
$user_agent = $_SERVER['HTTP_USER_AGENT'];
if($user_agent) {
if (strpos($user_agent, 'MSIE')) {
$body_classes[] = 'browser-ie';
} else if (strpos($user_agent, 'MSIE 6.0')) {
$body_classes[] = 'browser-ie6';
} else if (strpos($user_agent, 'MSIE 7.0')) {
$body_classes[] = 'browser-ie7';
//.........这里部分代码省略.........
示例15: guifi_graph_detail
//.........这里部分代码省略.........
}
}
if (isset($device_id)) {
$query = db_query("SELECT r.id, r.nick, n.title, r.nid, l.zone_id " . "FROM {guifi_devices} r, {node} n, {guifi_location} l " . "WHERE r.id=%d " . " AND n.nid=r.nid " . " AND n.nid = l.id", $device_id);
$radio = db_fetch_object($query);
$zid = $radio->zone_id;
}
if ($type == 'supernode') {
$node = node_load(array('nid' => $_GET['node']));
if ($node->graph_server == -1) {
$rows[] = array(t('This node has the graphs disabled.'));
return array_merge($rows);
}
if (!empty($node->graph_server)) {
$gs = node_load(array('nid' => $node->graph_server));
} else {
$gs = node_load(array('nid' => guifi_graphs_get_server($node->id, 'node')));
}
} else {
if ($radio->graph_server == -1) {
$rows[] = array(t('This device has the graphs disabled.'));
return array_merge($rows);
}
if (!empty($radio->graph_server)) {
$gs = node_load(array('nid' => $radio->graph_server));
} else {
$gs = node_load(array('nid' => guifi_graphs_get_server($radio->id, 'device')));
}
}
$help = t('Here you have a detailed view of the available information for several periods of time (daily, weekly, monthly and yearly). You can obtain a detailed graph for a given period of time by entering the period in the boxes below.');
$args = array('type' => $type, 'node' => $_GET['node'], 'device' => $device_id);
if (isset($_GET['direction'])) {
$args['direction'] = $_GET['direction'];
}
switch ($type) {
case 'clients':
$title = '<a href="' . base_path() . 'guifi/device/' . $radio->id . '">' . $radio->nick . '</a> ' . t('at') . ' ' . '<a href=' . base_path() . 'node/' . $radio->nid . '>' . $radio->title . '</a>';
$help .= '<br />' . t('The clients graph displays the top clients by transit.');
break;
case 'supernode':
$zid = $node->zone_id;
$title = '<a href=' . base_path() . 'node/' . $_GET['node'] . '>' . $node->title . '</a>';
$help .= '<br />' . t('Supernode graph displays the transit of each radio.');
break;
case 'radio':
case 'device':
$help = '<br />' . t('The radio graph show in & out transit.');
case 'pings':
if ($type != 'radio') {
$help = '<br />' . t('The ping graph displays the latency and availability. High latency usually means bad connection. Yellow means % of failed pings, could be some yellow on the graphs, but must not reach value of 100, if the value reaches 100, that means that the radio is offline.');
}
$title = $radio->nick . ' ' . t('at') . ' ' . '<a href=' . base_path() . 'node/' . $radio->nid . '>' . $radio->title . '</a>';
break;
}
$secs_day = 60 * 60 * 24;
drupal_set_breadcrumb(guifi_zone_ariadna($zid));
$output = '<div id="guifi">';
// $rows[] = array(t('enter a timeframe to graph a customized period'));
$output .= '<h3>' . $type . '</h3>' . $help;
switch ($type) {
}
if (isset($_POST['date1'])) {
$date1 = $_POST['date1'];
} else {
$date1 = date('d-m-Y H:i', time() - 60 * 60 * 2);
}
if (isset($_POST['date2'])) {
$date2 = $_POST['date2'];
} else {
$date2 = date('d-m-Y H:i', time() - 300);
}
$str = '<form name="form_timespan_selector" method="post"><strong> ' . t('From:');
$str .= ' </strong><input type="text" name="date1" id=\'date1\' size=\'14\' value="' . $date1 . '"> <input type="image"
src="' . base_path() . drupal_get_path('module', 'guifi') . '/contrib/calendar.gif" alt="Start date selector" onclick="return showCalendar(\'date1\');"> ';
$str .= '<strong>' . t('To:') . ' </strong> <input type="text" name="date2" id=\'date2\' size="14" value="' . $date2 . '"> ';
$str .= '<input type="image" src="' . base_path() . drupal_get_path('module', 'guifi') . '/contrib/calendar.gif" alt="End date selector" align="absmiddle" onclick="return showCalendar(\'date2\');"> ';
$str .= '<input type="submit" name="button_refresh" action="submit" value="refresh">';
$rows[] = array($str);
if (isset($_POST['date1'])) {
list($day, $month, $year, $hour, $min) = sscanf($_POST['date1'], '%d-%d-%d %d:%d');
$start = mktime($hour, $min, 0, $month, $day, $year);
list($day, $month, $year, $hour, $min) = sscanf($_POST['date2'], '%d-%d-%d %d:%d');
$end = mktime($hour, $min, 0, $month, $day, $year);
$rows[] = array(t('customized graph'));
$rows[] = array('<img src="' . guifi_cnml_call_service($gs->var['url'], 'graph', $args, sprintf('start=%d&end=%d">', $start, $end)));
}
$rows[] = array(t('day'));
$rows[] = array('<img src="' . guifi_cnml_call_service($gs->var['url'], 'graph', $args, sprintf('start=-%d&end=%d">', $secs_day, -300)));
$rows[] = array(t('week'));
$rows[] = array('<img src="' . guifi_cnml_call_service($gs->var['url'], 'graph', $args, sprintf('start=-%d&end=%d">', $secs_day * 7, -300)));
$rows[] = array(t('month'));
$rows[] = array('<img src="' . guifi_cnml_call_service($gs->var['url'], 'graph', $args, sprintf('start=-%d&end=%d">', $secs_day * 31, -300)));
$rows[] = array(t('year'));
$rows[] = array('<img src="' . guifi_cnml_call_service($gs->var['url'], 'graph', $args, sprintf('start=-%d&end=%d">', $secs_day * 365, -300)));
$output .= theme('table', NULL, array_merge($rows));
$output .= "</div>" . _guifi_script_calendar();
drupal_set_html_head('<script type="text/javascript" src="' . base_path() . drupal_get_path('module', 'guifi') . '/contrib/calendar.js"></script> <script type="text/javascript" src="' . base_path() . drupal_get_path('module', 'guifi') . '/contrib/lang/calendar-ca.js"></script></script> <script type="text/javascript" src="' . base_path() . drupal_get_path('module', 'guifi') . '/contrib/calendar-setup.js"></script>');
drupal_set_title(t('graph details for') . ' ' . $title);
return print theme('page', $output, t('graph details for') . ' ' . $title);
}