I’m kinda swamped right now, so this answer is kinda crappy. (I haven’t looked a xcomic yet. I did look at the walrus source code. Looks pretty neat, but the example setup they had at their site didn’t fully load, which I take as a bad sign.)
You should be able to do what you want to do with the regular one loop, and a handful of “if” statements actually. (Two loops might be more efficient.)
Basically, the way picoTokyo works, is that WordPress sees that it’s supposed to pull a post from the database, and checks to see if it belongs to the “webcomic” category. If it does, it styles it differently, and adds some buttons.
For what you want to do, you could just stick in the “if” statement I have below, set your blog to only show two posts at a time, and remember to put your comic in the second post (so it shows up at the top).
Let me show you what I mean:
In your index.php you’ll have these two lines:
1. <?php if (have_posts()) : ?>
2. <?php while (have_posts()) : the_post(); ?>
Translation:
1. WordPress, if you have a post today, do this:
2. While you have the post, show the post on the page.
After that bit, I add:
1. <?php if ( in_category('14') ) { ?>
2. <!-- use this html -->
3. <?php } else { ?>
4. <!-- use this html instead -->
5. <?php } ?>
Translation:
1. Is the post in category #14?
2. then do this!
3. Otherwise,
4. do this other thing.
If you want to stick buttons in Kubrick, then try this:
1. look for the line in index.php that begins with:
<p class="postmetadata">
2. Hit return, and paste this in. Change ’14’ to the category ID # your webcomics are in. Look at the categories menu under “Manage” and see what number is in the ID column next to your webcomic category.
<?php if ( in_category('14') ) { ?>
3. Then copy in the buttons you want to show there:
<!-- Buttons go here! -->
4. Add a linebreak so it doesn’t get mashed in with the rest of the post stuff.
<br>
5. Then paste in the rest of the if statement:
<?php } else { ?>
<!-- you don't need anything on this line -->
<?php } ?>
6. Make sure the next thing that shows up is
Posted in <?php the_category(', ') ?>
It should look like this:
<p class="postmetadata">
<?php if ( in_category('14') ) { ?>
<!-- Buttons go here! -->
<br>
<?php } else { ?>
<!-- you don't need anything on this line -->
<?php } ?>
<?php the_category(', ') ?>
WAIT! The buttons!
Here’s the code I use for the buttons, simplified a little. You can cut and paste that into the spot marked “buttons go here”.
<!-- this lets me put a box and a background around this button -->
<span class="button">
<!-- Copy the link from your first page and stick it here. -->
<!-- This is the "first" button -->
<a href="https://www.example.com/blog/index.php?paged=2">' ‹ ‹ first '</a>
<!-- this stops the box for this button from bleeding over to the next button -->
</span>
<!-- This is the "previous" button. -->
<?php posts_nav_link(' ',' ',' <span class="button"> ‹ previous </span>'); ?>
<!-- This is the "next" button. -->
<?php posts_nav_link(' ','<span class="button"> next ›</span> ',' '); ?>
<!-- This is the "today" button. -->
<span class="button">''<a href="/blog"> today › › </a></span></span>
<br>
===
You’ll need to add these lines to your styles.css, too:
.button
{
color: black; /* this is the text color */
background-color: yellow; /* this is the color of the button */
border-style: solid;
border-width: 1px;
border-color: black;
}
Whew! That was a lot of crap. Sorry to bury you. I don’t even know if I answered your question!
-R.
EDIT: fixed backticks