mgsisk / webcomic

Comic publishing power for the web. Turn your WordPress-powered site into a comic publishing platform with Webcomic.
http://wordpress.org/plugins/webcomic
GNU General Public License v2.0
110 stars 29 forks source link

Update borked blog posts associated with comics. #173

Closed Seel closed 10 years ago

Seel commented 10 years ago

So this is weird, the proper post associated with the comic appears on the comic-homepages:

http://ahs-comic.com/ http://ahs-comic.com/iff/

No problems there.

But if you look at individual pages they all have the same post:

http://ahs-comic.com/archive/page-79 http://ahs-comic.com/archive/page-78 http://ahs-comic.com/archive/page-77 etc.

Funnily enough, everything else including the title is correct though. Comments are also fine.

The posts are all from this page: http://ahs-comic.com/gallery/idly-falling-feathers/

This is not the most recent page, but it's the only page I posted In a third webcomic collection I started recently to use as a gallery.

mgsisk commented 10 years ago

Apologies for the trouble seel; I'll look into this immediately. As a temporary fix, try removing your "Recent Updates" widget, as I think the last post in that is messing with things (I'm not sure why, however, and it definitely shouldn't, so this is a bug of some kind, probably with the Recent Webcomics widget).

Seel commented 10 years ago

Okay, that did it for now. I wouldn't have guessed that a widget would be the culprit. Guess I can live without it for a while.

mgsisk commented 10 years ago

I just pushed an update to WordPress.org that might address this issue. Please let me know if it does.

Seel commented 10 years ago

Hmm no, I don't think it did. As soon as I put the [Webcomic] Recent widget in the sidebar the problem reappears.

Seel commented 10 years ago

That sidebar I have the widget in is a special "comic-sidebar" I created to only appear next to comics and it was in the <?php while ( have_posts() ) : the_post(); ?> loop. Now I don't know if what I was doing there was bad thing or not, because I'm not too good with coding, so I just put it outside the loop for now and I guess that's fine?

Apologies if this is actually only an issue because I am incompetent at stuff. <_<

mgsisk commented 10 years ago

Well… sort of, maybe. XD What happened when you put the sidebar inside the loop like that was that you ended up with a loop inside a loop, which WordPress recommends avoiding. There are ways to make nested loops like that work, however. I'm going to close this for now, but I'm still going to look and see if there's a way I can get the widgets and template tags that use loops to work in situations like this.