Commit f543546d authored by l26yan's avatar l26yan
Browse files

add export to individual event

parent c0e2757b
......@@ -25,4 +25,7 @@
line-height: 16px;
margin-bottom: 10px;
padding-left: 40px;
}
\ No newline at end of file
}
.individual-event-ical a {
margin-left: 0.5em;
}
......@@ -78,28 +78,29 @@
* @see template_process()
*/
?>
<?php
$feed_url = "feed/" . $node->nid;
?>
<h1<?php print $title_attributes; ?> class="individual-event-ical"><?php print $title; ?><a href="<?php print $feed_url; ?>"><img src="/profiles/uw_base_profile/themes/uw_fdsu_theme/images/add-calendar-icon-33x20.png" alt="Export this event to calendar" title="Export this event to calendar"></a>
</h1>
<div class="clearfix"<?php print $attributes; ?>>
<div class="event-content"<?php print $content_attributes; ?>>
<?php if (!$page): ?>
<?php print render($title_prefix); ?>
<h2<?php print $title_attributes; ?>><a href="<?php print $node_url; ?>"><?php print $title; ?></a></h2>
<?php print render($title_suffix); ?>
<?php endif; ?>
<?php endif; ?>
<div class="event-content"<?php print $content_attributes; ?>>
<?php print render($content['field_event_date']); ?>
<?php print render($content['field_event_date']); ?>
<?php print render($content['body']); ?>
<div class="details">
<?php
// We hide the comments and links now so that we can render them later.
hide($content['comments']);
hide($content['links']);
print render($content);
?>
?>
</div>
</div>
<?php print render($content['links']); ?>
</div>
\ No newline at end of file
</div>
......@@ -3,7 +3,7 @@ description = Adds events and event listing pages.
core = 7.x
package = uWaterloo Content Types
php = 5.2.4
version = 7.x-1.15-trunk
version = 7.x-1.16-trunk
project = uw_ct_event
dependencies[] = calendar
dependencies[] = context
......
......@@ -380,6 +380,11 @@ function uw_ct_event_link_field_process($element, $form_state, $complete_form) {
* Implements hook_theme_registry_alter().
*/
function uw_ct_event_theme_registry_alter(&$theme_registry) {
$theme_registry['page__node__uw_event'] = array(
'template' => 'page--node--uw-event',
'path' => drupal_get_path('module', 'uw_ct_event') . '/templates',
'type' => 'theme',
);
$theme_registry['node__uw_event'] = array(
'template' => 'node--uw-event',
'path' => drupal_get_path('module', 'uw_ct_event') . '/templates',
......@@ -400,6 +405,7 @@ function uw_ct_event_theme_registry_alter(&$theme_registry) {
'path' => drupal_get_path('module', 'uw_ct_event') . '/templates',
'type' => 'theme',
);
}
/**
......@@ -445,7 +451,7 @@ function events_public_feed_link() {
function uw_ct_event_calendar_contents() {
global $base_url;
$link = $base_url . '/calendar/ical/' . date('Y') . '/calendar.ics';
$image_path = drupal_get_path('module', 'uw_ct_event') . '/images/ical-feed-icon-34x14.png';
//$image_path = drupal_get_path('module', 'uw_ct_event') . '/images/ical-feed-icon-34x14.png';
$html = '<div class="feed-icon">';
$html .= '<a class="ical-icon" href="' . $link . '">';
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment