Source

elbee-elgee / navigation.php

Diff from to

File navigation.php

 <?php
 /**
- * 
+ * Template Name: Navigation
  */
 ?>
 	<!--hr /-->
 
-	<?php if ( is_single() ) { ?>
+	<?php if ( is_attachment() ) { ?>
+
+	<div class="navigation">
+		<div class="left"><?php previous_image_link( 0 ) ?></div>
+		<div class="right"><?php next_image_link( 0 ) ?></div>
+		<div class="clear"></div>
+	</div>		
+
+	<?php } elseif ( is_single() ) { ?>
 
 	<div class="navigation">
 		<div class="left"><?php previous_post_link() ?></div>
 	</div>
 
 	<?php } else { ?>
+
 	<div class="navigation">
 			<?php if(function_exists('wp_pagenavi')) {
  					wp_pagenavi();