added back storyline chapters to comic posts links, fixed the graphical navigationt o handle johns storylines, sidebar-right.php fixed comicpress_calendar link

Signed-off-by: Philip M. Hofer (Frumph) <frumph_dragon@yahoo.com>
This commit is contained in:
Philip M. Hofer (Frumph) 2009-08-26 21:17:24 -07:00
parent 2b863e844f
commit cc7519e964
5 changed files with 184 additions and 190 deletions

View File

@ -325,23 +325,44 @@ function get_terminal_post_in_category($categoryID, $first = true) {
/** /**
* Find the first post in the storyline prior to the current one. * Find the first post in the storyline prior to the current one.
*/ */
function get_previous_storyline_start_permalink() { function get_previous_storyline_start() {
if (($category_id = get_adjacent_storyline_category_id()) !== false) { if (($category_id = get_adjacent_storyline_category_id(true)) !== false) {
return get_terminal_post_in_category($category_id); return get_terminal_post_in_category($category_id);
} }
return false; return false;
} }
function get_previous_storyline_start_permalink() {
$prev_story = get_previous_storyline_start();
if (is_object($prev_story)) {
if (isset($prev_story->ID)) {
return get_permalink($prev_story->ID);
}
}
return false;
}
/** /**
* Find the first post in the storyline following to the current one. * Find the first post in the storyline following to the current one.
*/ */
function get_next_storyline_start_permalink() { function get_next_storyline_start() {
if (($category_id = get_adjacent_storyline_category_id(true)) !== false) { if (($category_id = get_adjacent_storyline_category_id()) !== false) {
return get_terminal_post_in_category($category_id); return get_terminal_post_in_category($category_id);
} }
return false; return false;
} }
function get_next_storyline_start_permalink() {
$next_story = get_next_storyline_start();
if (is_object($next_story)) {
if (isset($next_story->ID)) {
return get_permalink($next_story->ID);
}
}
return false;
}
function get_adjacent_storyline_category_id($next = false) { function get_adjacent_storyline_category_id($next = false) {
global $post, $category_tree; global $post, $category_tree;

View File

@ -32,6 +32,9 @@ function display_comic_post() {
<div class="post-text"> <div class="post-text">
<h2><a href="<?php the_permalink(); ?>" rel="bookmark" title="Permanent Link to <?php the_title(); ?>"><?php the_title(); ?></a></h2> <h2><a href="<?php the_permalink(); ?>" rel="bookmark" title="Permanent Link to <?php the_title(); ?>"><?php the_title(); ?></a></h2>
<small> By <?php the_author_posts_link(); ?> on <?php the_time('F jS, Y'); ?> <?php edit_post_link('Edit Post', ' [ ', ' ] '); ?></small><br /> <small> By <?php the_author_posts_link(); ?> on <?php the_time('F jS, Y'); ?> <?php edit_post_link('Edit Post', ' [ ', ' ] '); ?></small><br />
<?php if (get_option('comicpress-enable-storyline-support') == 1) { ?>
<ul class="storyline-cats"><li class="storyline-root"><?php the_category(' &raquo; </li><li>', multiple) ?></li></ul>
<?php } ?>
<?php if(function_exists('the_ratings')) { the_ratings(); } ?> <?php if(function_exists('the_ratings')) { the_ratings(); } ?>
</div> </div>
<div class="clear"></div> <div class="clear"></div>

View File

@ -8,7 +8,7 @@
<?php if (is_cp_theme_style('standard,v')) { ?> <?php if (is_cp_theme_style('standard,v')) { ?>
<ul> <ul>
<li> <li>
<?php get_calendar() ?> <?php comicpress_calendar() ?>
</li> </li>
</ul> </ul>
<?php } ?> <?php } ?>

View File

@ -22,33 +22,27 @@ body {
z-index: 0; z-index: 0;
} }
a { a {
color: #800; color: #800;
text-decoration: none; text-decoration: none;
} }
a:hover { a:hover {
color: #f00; color: #f00;
} }
a:focus { a:focus {
outline: none; outline: none;
} }
a img { a img {
border: none; border: none;
} }
p { p {
margin: 12px 0; margin: 12px 0;
} }
img { img {
max-width: 100%; max-width: 100%;
padding: 0; padding: 0;
@ -1211,25 +1205,20 @@ li.pingback div p, li.trackback div p {
margin-left: 0; margin-left: 0;
} }
/* STORYLINES */ /* STORYLINES */
.storyline-cats {
#storyline-cats {
padding: 0; padding: 0;
margin: 0 10px 0 0; margin: 0;
list-style: none; list-style: none;
} }
.storyline-cats li {
#storyline-cats li {
display: inline; display: inline;
} }
li.storyline-root {
#storyline-cats ul { display: none;
display: inline;
margin-right: 10px;
} }
@ -1240,11 +1229,6 @@ li.pingback div p, li.trackback div p {
clear: both; clear: both;
} }
/* CLEAR MARGINS */ /* CLEAR MARGINS */
/* Used with BR for clearing paragraph margins for Safari, Chrome - avoid background gaps */ /* Used with BR for clearing paragraph margins for Safari, Chrome - avoid background gaps */
@ -1256,12 +1240,6 @@ li.pingback div p, li.trackback div p {
font-size: 0; font-size: 0;
} }
/** BUY THIS **/ /** BUY THIS **/
@ -1286,7 +1264,6 @@ li.pingback div p, li.trackback div p {
width: 100%; width: 100%;
} }
.headerpwad { .headerpwad {
float: right; float: right;
margin: 5px 5px 0 0; margin: 5px 5px 0 0;
@ -1298,11 +1275,8 @@ li.pingback div p, li.trackback div p {
text-align: center; text-align: center;
} }
/* Archive Calendar Template */ /* Archive Calendar Template */
.cpcal-month { .cpcal-month {
width: 157px; width: 157px;
height: 138px; height: 138px;
@ -1323,6 +1297,7 @@ li.pingback div p, li.trackback div p {
line-height: 16px; line-height: 16px;
letter-spacing: -1px; letter-spacing: -1px;
} }
.cpcal-dayletter { .cpcal-dayletter {
width: 20px; width: 20px;
height: 15px; height: 15px;
@ -1362,7 +1337,6 @@ li.pingback div p, li.trackback div p {
/* Storyline Template */ /* Storyline Template */
#storyline, #storyline ul { #storyline, #storyline ul {
padding: 0; padding: 0;
margin: 0; margin: 0;
@ -1621,11 +1595,8 @@ a.tt:hover span.bottom {
padding: 0; padding: 0;
} }
.userpage-posts li { .userpage-posts li {
list-style: none; list-style: none;
margin: 0; margin: 0;
padding: 0; padding: 0;
} }

View File

@ -25,14 +25,13 @@ class widget_comicpress_graphical_navigation extends WP_Widget {
$wp_query->is_single = true; $wp_query->is_single = true;
$prev_comic = get_previous_comic_permalink(); $prev_comic = get_previous_comic_permalink();
$next_comic = get_next_comic_permalink(); $next_comic = get_next_comic_permalink();
$prev_story = get_previous_storyline_start_permalink();
$next_story = get_next_storyline_start_permalink();
$wp_query->is_single = $temp_query; $wp_query->is_single = $temp_query;
$temp_query = null; $temp_query = null;
$first_comic = get_first_comic_permalink(); $first_comic = get_first_comic_permalink();
$last_comic = get_last_comic_permalink(); $last_comic = get_last_comic_permalink();
$prev_story = get_previous_storyline_start_permalink();
$next_story = get_next_storyline_start_permalink();
?> ?>
<div id="comic_navi_wrapper"> <div id="comic_navi_wrapper">