made first sketch for custom loop, with lightboxes

This commit is contained in:
Sjur Hernes committed 2011-07-18 07:03:48 +02:00
1 parent 2e5e4814d7
commit ad945881ae
3 files changed
+66

No files matched your search

+2
View File
@@ -71,6 +71,8 @@ class Artist_Widget extends WP_Widget {
register_widget('Program_Widget'); register_widget('Program_Widget');
register_widget('Artist_Widget'); register_widget('Artist_Widget');
add_filter('widget_text', 'do_shortcode');
function get_related_artists( $post_id) function get_related_artists( $post_id)
{ {
+4
View File
@@ -38,6 +38,10 @@
<link rel="stylesheet" type="text/css" media="all" href="<?php bloginfo( 'stylesheet_directory' ); ?>/studio.css" /> <link rel="stylesheet" type="text/css" media="all" href="<?php bloginfo( 'stylesheet_directory' ); ?>/studio.css" />
<script type="text/javascript" src="<?php bloginfo( 'stylesheet_directory' ); ?>/scripts/jquery.lightbox-0.5.pack.js"></script> <script type="text/javascript" src="<?php bloginfo( 'stylesheet_directory' ); ?>/scripts/jquery.lightbox-0.5.pack.js"></script>
<script type="text/javascript" src="<?php bloginfo('template_url'); ?>/frontbox/fbox_conf.js"></script>
<script type="text/javascript" src="<?php bloginfo('template_url'); ?>/frontbox/fbox_engine-min.js"></script>
<link rel="stylesheet" href="<?php bloginfo('template_url'); ?>/frontbox/fbox.css" type="text/css" />
<link rel="pingback" href="<?php bloginfo( 'pingback_url' ); ?>" /> <link rel="pingback" href="<?php bloginfo( 'pingback_url' ); ?>" />
<?php <?php
/* We add some JavaScript to pages with the comment form /* We add some JavaScript to pages with the comment form
+60
View File
@@ -0,0 +1,60 @@
<h1>Nyheter</h1>
<?php
global $post, $wp_locale;
$news = new WP_Query( array('post_type' => 'post',
'posts_per_page' => 10,
'order' => 'DESC'
));
if ($news->have_posts()) : while ($news->have_posts()) : $news->the_post(); ?>
<div class="post" id="post-<?php the_ID(); ?>">
<h2><a href="#"><span class="frontbox" src="#hidpos-<?php the_ID(); ?>" height="420" title="<?php the_title(); ?>"></span><?php the_title(); ?></a><a href="<?php the_permalink(); ?>" rel="bookmark" ></a></h2>
<p class="meta">Posted on <?php the_time('F jS, Y'); ?></p>
<div id="hidpos-<?php the_ID(); ?>" style="display:none"><?php the_content(); ?></div>
<p><?php the_tags('Tags: ', ', ', '<br />'); ?> Posted in <?php the_category(', '); ?> | <?php edit_post_link('Edit', '', ' | '); ?> <?php comments_popup_link('No Comments &#187;', '1 Com &#187;', '% Comments &#187;'); ?></p>
</div>
<?php endwhile; ?>
<?php next_posts_link('&laquo; Older Entries') ?>
<?php previous_posts_link('Newer Entries &raquo;') ?>
<?php else : ?>
<h2>No Posts Found</h2>
<?php endif; ?>
<hr />
<h1>Program</h1>
<?php
$events = new WP_Query( array(
'post_type' => 'event',
'posts_per_page' => -1,
'meta_key' => 'neuf_events_starttime',
'orderby' => 'meta_value',
'order' => 'ASC'
) );
if ($events->have_posts()) : while ($events->have_posts()) : $events->the_post(); ?>
<div class="post" id="post-<?php the_ID(); ?>">
<h2>
<a href="#"><span class="frontbox" src="#hidpos-<?php the_ID(); ?>" height="420" title="<?php the_title(); ?>"></span><?php the_title(); ?></a><a href="<?php the_permalink(); ?>" rel="bookmark" ></a>
<a href="<?php the_permalink(); ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>"><?php the_title(); ?></a></h2>
<p class="meta">Posted on <?php the_time('F jS, Y'); ?></p>
<div id="hidpos-<?php the_ID(); ?>" style="display:none"><?php the_content(); ?></div>
<p><?php the_tags('Tags: ', ', ', '<br />'); ?> Posted in <?php the_category(', '); ?> | <?php edit_post_link('Edit', '', ' | '); ?> <?php comments_popup_link('No Comments &#187;', '1 Com &#187;', '% Comments &#187;'); ?></p>
</div>
<?php endwhile; ?>
<?php next_posts_link('&laquo; Older Entries') ?>
<?php previous_posts_link('Newer Entries &raquo;') ?>
<?php else : ?>
<h2>No Events Found</h2>
<?php endif; ?>