Hi, I wonder if someone can please help? I'm totally new to php (and all coding in general...). I have a website and everything was working fine, I haven't touched the code, but I installed a new plugin and now my categories/archive won't work.
The error is: Parse error: syntax error, unexpected T_ELSEIF in /home/thislittlelady/thislittleladywenttolondon.com/wp-content/themes/arthemia/archive.php on line 13
The code is;
<?php get_header(); ?>
<div id="content">
<?php if (have_posts()) : ?>
<span class="breadcrumbs"><a href="<?php echo get_option('home'); ?>/">Home</a> » Archive</span>
<?php $post = $posts[0]; // Hack. Set $post so that the_date() works. ?>
<?php /* If this is a category archive */ if(function_exists(page2cat_output)): page2cat_output($cat); else: { ?> <h2 class="title">Articles in the <?php single_cat_title(); ?> Category</h2>
<?php /* If this is a tagged archive */ } elseif (is_tag()) { ?> <h2 class="title">Articles tagged with <?php single_tag_title(); ?></h2>
<?php /* If this is a daily archive */ } elseif (is_day()) { ?> <h2 class="title">Articles Archive for <?php the_time('j F Y'); ?></h2>
<?php /* If this is a monthly archive */ } elseif (is_month()) { ?><h2 class="title">Articles Archive for <?php the_time('F Y'); ?></h2>
<?php /* If this is a yearly archive */ } elseif (is_year()) { ?><h2 class="title">Articles Archive for Year <?php the_time('Y'); ?></h2>
<?php /* If this is a paged archive */ } elseif (isset($_GET['paged']) && !empty($_GET['paged'])) { ?><h2 class="title">The Archives</h2>
<?php ; ?>
<div id="archive">
<?php while (have_posts()) : the_post(); ?>
<div class="clearfloat">
<h3 class=cat_title><?php the_category(', '); ?> »</h3>
<div class="title"><a href="<?php the_permalink() ?>" rel="bookmark"><?php the_title(); ?></a></div>
<div class="meta">[<?php the_time('j M Y') ?> | <?php comments_popup_link('No Comment', 'One Comment', '% Comments');?> | <?php if(function_exists('the_views')) { the_views(); } ?>]</div>
<div class="spoiler">
<?php $values = get_post_custom_values("Image");
if (isset($values[0])) { ?>
<a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title(); ?>">
<img src="<?php echo bloginfo('template_url'); ?>/scripts/timthumb.php?src=/<?php
$values = get_post_custom_values("Image"); echo $values[0]; ?>&w=150&h=150&zc=1&q=100"
alt="<?php the_title(); ?>" class="left" width="150px" height="150px" /></a>
<?php } ?>
<?php the_excerpt(); ?>
</div>
</div>
<?php endwhile; ?>
<div class="navigation">
<?php if(function_exists('wp_pagenavi')) { wp_pagenavi(); }
else { ?>
<div class="right"><?php next_posts_link('Next Page »') ?></div>
<div class="left"><?php previous_posts_link('« Previous Page') ?></div>
<?php } ?>
</div>
<?php else; ?>
<h2 class="title">No posts found. Try a different search?</h2>
<?php endif; ?>
</div>
</div>
<?php get_sidebar(); ?>
<?php get_footer(); ?>
I'm guessing there's a semi colon missing, or an open bracket somewhere - but if anyone has any suggestions on how to fix I'd be REALLY grateful!
Thanks
JJ :o