Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php get_header(); ?>
- <div id="wrapper">
- <div class="sidebar">
- <nav id="options">
- <ul id="sort-by" class="option-set clearfix" data-option-key="sortBy">
- <li><a href="#sortBy=blogs" data-option-value="blogs" title="" class="c">Blogs</a></li>
- <li><a href="#sortBy=artists" data-option-value="artists" title="" class="g">Artists</a></li>
- <li><a href="#sortBy=development" data-option-value="development" title="" class="l">Development</a></li>
- <li><a href="#sortBy=projects" data-option-value="projects" title="" class="p">Projects</a></li>
- <li><a href="#sortBy=offsite" data-option-value="offsite" title="" class="y">Offsite</a></li>
- <li><a href="#sortBy=contact" data-option-value="contact" title="" class="my">Contact</a></li>
- </ul>
- </nav>
- <div id="newsletter-wrap">
- <p>Subscribe</p>
- <form id="subscribe" action="" method="">
- <input type="text" name="name" value="" id="name" placeholder="Name" required />
- <input type="email" name="email" value="" id="email" placeholder="Email" required />
- </form>
- </div>
- <footer>
- <?php
- $pageintro=get_post_meta($post->ID,'Page_Intro',true);
- if($pageintro != '') {
- echo '<p>'. $pageintro .'</p>';
- } else {
- echo ' ';
- }
- ?>
- <?php
- $pageintroref=get_post_meta($post->ID,'Page_Intro_Ref',true);
- if($pageintroref != '') {
- echo '<p>'. $pageintroref .'</p>';
- } else {
- echo ' ';
- }
- ?>
- </footer>
- </div> <!--! /sidebar -->
- <div id="main" role="main">
- <?php
- // Query just the category static and make the link manually editable through the 'URL' custom field
- $paged = (get_query_var('paged')) ? get_query_var('paged') : 1;
- $args= array(
- 'category_name' => 'static',
- 'paged' => $paged
- );
- query_posts($args);
- if( have_posts() ) :?>
- <?php while (have_posts()) : the_post(); ?>
- <?php foreach( get_the_category() as $cat ) echo '<div class="module ' . $cat->slug . '" data-category="' . $cat->slug . '" >'; ?>
- <a href="<?php echo get_post_meta($post->ID, 'URL', true); ?>" title="<?php the_title(); ?>">
- <!-- IF POST ID = x, DISPLAY HARD CODED FLICKR SLIDESHOW ELSE DISPLAY NORMALLY -->
- <div class="active">
- <div class="hover"></div>
- <?php the_post_thumbnail(); ?>
- </div>
- <!-- im trying to put your code in here but it just won't work -->
- <h1><?php the_title(); ?></h1>
- <?php
- // Call in the contents of a custom field called Excerpt and if custom field in admin panel is empty don't display <p> tags otherwise wrap contents in <p> tags
- $excerpt=get_post_meta($post->ID,'Excerpt',true);
- if($excerpt != '') {
- echo '<p>'. $excerpt .'</p>';
- } else {
- echo ' ';
- }
- ?>
- <p class="date"><!-- for sorting boxes, use post id or date format must be yyyyMMdd--><?php the_time('Ydm') ?></p>
- </a>
- </div>
- <?php endwhile; ?>
- <?php endif; ?>
- <?php
- // Query all other categories and display them the normal way
- $paged = (get_query_var('paged')) ? get_query_var('paged') : 1;
- $args= array(
- 'category_name' => 'blogs, artists, development, projects, offsite, contact',
- 'paged' => $paged
- );
- query_posts($args);
- if( have_posts() ) :?>
- <?php while (have_posts()) : the_post(); ?>
- <!-- if sticky post or is category slug static then display a different box than the rest (i.e. no link and make h1 tag link to match the url entered in custom field) Need to control where the sticky post is originally displayed on page -->
- <?php foreach( get_the_category() as $cat ) echo '<div class="module ' . $cat->slug . '" data-category="' . $cat->slug . '" >'; ?>
- <a href="<?php the_permalink()?>" title="<?php the_title(); ?>">
- <div class="active">
- <div class="hover"></div>
- <?php the_post_thumbnail(); ?>
- </div>
- <!-- im trying to put your code in here but it just won't work -->
- <h1><?php the_title(); ?> <span>/ Explode here</span></h1>
- <?php
- // Call in the contents of a custom field called Excerpt and if custom field in admin panel is empty don't display <p> tags otherwise wrap contents in <p> tags
- $excerpt=get_post_meta($post->ID,'Excerpt',true);
- if($excerpt != '') {
- echo '<p>'. $excerpt .'</p>';
- } else {
- echo ' ';
- }
- ?>
- <p class="date"><!-- for sorting boxes, use post id or date format must be yyyyMMdd--><?php the_time('Ydm') ?></p>
- </a>
- </div>
- <?php endwhile; ?>
- <?php endif; ?>
- </div> <!--! /main -->
- <?php get_footer(); ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement