示例#1
0
							.post-navigation .nav-next a:before { 
								background-color: rgba(0, 0, 0, 0.2); 
							}
						';
        ?>
 <style> <?php 
        echo $css;
        ?>
 </style> <?php 
        $css = "";
    }
    ?>
										
					<div class="nav-next">
						<a href="<?php 
    echo WebcomicTag::get_relative_webcomic_term_link("archive", "next", "storyline");
    ?>
" rel="next">
							<span class="meta-nav" aria-hidden="true">Next</span> 
							<span class="screen-reader-text">Next storyline archive:</span> 
							<span class="post-title"><?php 
    echo $storylineObj[$next_story]->name;
    ?>
</span>
						</a>
					</div>
				<?php 
}
?>
					
				</div>
示例#2
0
									background-color: rgba(0, 0, 0, 0.2); 
								}
							';
            ?>
 <style> <?php 
            echo $css;
            ?>
 </style> <?php 
            $css = "";
        }
        ?>
						
					
						<div class="nav-next">
							<a href="<?php 
        echo WebcomicTag::get_relative_webcomic_term_link("archive", "next", "character");
        ?>
" rel="next">
								<span class="meta-nav" aria-hidden="true">Next Character</span> 
								<span class="screen-reader-text">Next character archive:</span> 
								<span class="post-title"><?php 
        echo $characterObj[$next_char]->name;
        ?>
</span>
							</a>
						</div>
					<?php 
    }
    ?>
					
					</div>
示例#3
0
 /**
  * Handle parameterized webcomic URL's.
  * 
  * @uses WebcomicTag::get_relative_webcomic_term_link()
  * @uses WebcomicTag::get_relative_webcomic_link()
  * @hook init
  */
 public function webcomic_redirect()
 {
     $link = '';
     if (isset($_GET['first_webcomic']) or isset($_GET['last_webcomic']) or isset($_GET['random_webcomic'])) {
         if (isset($_GET['first_webcomic'])) {
             $relative = 'first';
         } elseif (isset($_GET['last_webcomic'])) {
             $relative = 'last';
         } else {
             $relative = 'random';
         }
         $in_same_term = empty($_GET['in_same_term']) ? false : maybe_unserialize(stripslashes(urldecode($_GET['in_same_term'])));
         $excluded_terms = empty($_GET['excluded_terms']) ? false : maybe_unserialize(stripslashes(urldecode($_GET['excluded_terms'])));
         $taxonomy = empty($_GET['taxonomy']) ? false : maybe_unserialize(stripslashes(urldecode($_GET['taxonomy'])));
         $collection = empty($_GET["{$relative}_webcomic"]) ? array_rand(self::$config['collections']) : $_GET["{$relative}_webcomic"];
         $link = WebcomicTag::get_relative_webcomic_link($relative, $in_same_term, $excluded_terms, $taxonomy, $collection);
     } elseif (isset($_GET['first_webcomic_term']) or isset($_GET['last_webcomic_term']) or isset($_GET['random_webcomic_term'])) {
         $target = empty($_GET['target']) ? 'archive' : $_GET['target'];
         if (isset($_GET['first_webcomic_term'])) {
             $relative = 'first';
         } elseif (isset($_GET['last_webcomic_term'])) {
             $relative = 'last';
         } else {
             $relative = 'random';
         }
         if (empty($_GET["{$relative}_webcomic_term"])) {
             $taxonomy = array_rand(self::$config['collections']) . '_' . array_rand(array('storyline' => true, 'character' => true));
         } else {
             $taxonomy = $_GET["{$relative}_webcomic_term"];
         }
         $args = empty($_GET['args']) ? false : maybe_unserialize(stripslashes(urldecode($_GET['args'])));
         $link = WebcomicTag::get_relative_webcomic_term_link($target, $relative, $taxonomy, $args);
     }
     if ($link) {
         wp_redirect($link);
         die;
     }
 }