Comic Fury Webcomic Hosting - Showing just the latest chapter on extra page?

You are not logged in. Log in, Register, More info
Forum > Layouts, HTML, CSS & Javascript > Showing just the latest chapter on extra page?
Pages: [1]

"Showing just the latest chapter on extra page?", 10 days ago, 10:11 PM #1
BeeMKay

Posts: 15
Registration date: 22nd Sep 2017
Location: Germany
I intend to have an info page that shows, instead of the entire archive listing, just the newest chapter posted. Is that possible? I have to admit that the code guide was confusing.
_______________________
Demon Division (English Version) http://demondivision.thecomicseries.com/
Demon Division (German Version) http://demondivision-de.thecomicseries.com
Demon Division: Dwellers (English Version) http://divisiond-dwellers.thecomicseries.com/
Demon Division: Dwellers (German Version) http://divisiond-dwellers-de.thecomicseries.com
10 days ago, 10:43 PM #2
Robotwin.com

User avatar
Posts: 2811
Registration date: 22nd Sep 2010
Location: USA, Milky Way
From the layout reference:
[v:chapterlink]
Link to the comic archive page for the chapter that the displayed comic is part of.


I interpret this to mean that you have to make a special menu option targeting [v:chapterlink] and then Comic Fury will automatically generate a limited archive loop for that chapter alone when a visitor clicks on it.

So if you have 12 Chapters, it will always link to the chapter archive index for that specific page, not always the latest chapter, unless it's the latest pages. (Though I haven't tried it to be sure) Yeap, I tried it and it works pretty much like that.

Since [v:chapterlink] generates a unique URL for that chapter like "http://webomic.com/archive/22001", you can hard code that link into your menu whenever you create a new chapter.

Another thing you can do is rearrange your chapter order index. Since the lowest index will always be the first to display in the generic archive page, set the latest chapter to index 0, then you can use CSS to hide all the rest of the rows in the archive table. That might be a bad idea because some (if not most) readers like to be able to see the entire archive index.
10 days ago, 11:58 PM #3
Kyo
family life
User avatar
Posts: 17838
Registration date: 6th Jul 2008
Location: Germany
it actually is possible, but not without some fuckery:

The last chapter is: [l:@chapteredarchive]
    [c:l.is_first]
        [v:l.chaptername]
    [/]
[/]


explanation:

[l:chapteredarchive] is a loop of all your comics, sorted by chapter, along with their chapter information

putting that @ in front of the loop name reverses the loop order, so it'll start with the last comic and work it's way up.

[c:l.is_first] is actually a condition built into the template engine, you can use it in any loop, and it'll always be true only if we're running through the loop for the first time (so in this case, if we're on the last comic) - this part is only so that it'll only spit out the chaptername exactly once, rather than for every comic in the loop.

[v:l.chaptername] returns the name of the chapter the current comic is in.

There's also:
[v:l.chapterarchiveurl] for a link to the archive for just that chapter
[v:l.chapterid] for the internal ID of the chapter (useful mostly for comparisons)
[v:l.chapterdescription] for the chapter description

unless I misunderstood and you're trying to show an archive including all comics, but only for the latest chapter?
_______________________
hello
9 days ago, 12:12 AM #4
Robotwin.com

User avatar
Posts: 2811
Registration date: 22nd Sep 2010
Location: USA, Milky Way
You're maybe sleepy Kyo, cause that's exactly what he asked for. :p
9 days ago, 12:14 AM #5
BeeMKay

Posts: 15
Registration date: 22nd Sep 2017
Location: Germany
That looks good, Kyo. And if I want to have the newest chapter, and in that chapter just the newest strip?

EDIT: Har, Har! found it out through experimenting...
<ul>
<li class="archivecomic">
[l:@chapteredarchive] 
[c:l.is_first] 
<a href="[v:l.comicurl]">[v:l.comictitle]</a> ([v:l.posttime])</li>
<li>
		[/] [/]</li>
</ul>


Thank you Robotwin and Kyo!
_______________________
Demon Division (English Version) http://demondivision.thecomicseries.com/
Demon Division (German Version) http://demondivision-de.thecomicseries.com
Demon Division: Dwellers (English Version) http://divisiond-dwellers.thecomicseries.com/
Demon Division: Dwellers (German Version) http://divisiond-dwellers-de.thecomicseries.com
2 days ago, 10:33 AM #6
BeeMKay

Posts: 15
Registration date: 22nd Sep 2017
Location: Germany
Okay... upping the difficulty of this linking business...
After including the link for the comic/Chapter's page for the current comic, is there a way to do this for othe comics of my series? The goal is as follows: My comic is split up into two series and each series has two languages. What I'd like to do is to display the latest added page for each into my table, so I can basically have the same table displayed in all four series. Is that possible?

Here's the example page I created, but of course it has just the Page-link for the comic it is part of in:

http://demondivision.thecomicseries.com/languageseries
_______________________
Demon Division (English Version) http://demondivision.thecomicseries.com/
Demon Division (German Version) http://demondivision-de.thecomicseries.com
Demon Division: Dwellers (English Version) http://divisiond-dwellers.thecomicseries.com/
Demon Division: Dwellers (German Version) http://divisiond-dwellers-de.thecomicseries.com
2 days ago, 11:08 AM #7
Kyo
family life
User avatar
Posts: 17838
Registration date: 6th Jul 2008
Location: Germany
assuming your comics will always have the exact same number of strips, in the exact same order, you could abuse the fact that links are relative, rather than absolute, and just prepend the german translation's URL to the variable.

So like...

<a href="http://germantranslation.cfw.me[v:l.comicurl]">


this is obviously pretty hacky, but should work
_______________________
hello
2 days ago, 11:32 AM #8
BeeMKay

Posts: 15
Registration date: 22nd Sep 2017
Location: Germany
Thanks, Kyo.
That would probably work for the link, but the page titles are different (German it's "Seite 10" instead of "Page 10").
I'll work that into the page anyway.
_______________________
Demon Division (English Version) http://demondivision.thecomicseries.com/
Demon Division (German Version) http://demondivision-de.thecomicseries.com
Demon Division: Dwellers (English Version) http://divisiond-dwellers.thecomicseries.com/
Demon Division: Dwellers (German Version) http://divisiond-dwellers-de.thecomicseries.com
2 days ago, 12:03 PM #9
Kyo
family life
User avatar
Posts: 17838
Registration date: 6th Jul 2008
Location: Germany
you could also pull it in via javascript. If you create an extra page, don't embed it in the layout, don't process new lines, page order 0 so it doesn't show up in the navigation menu, and then just format the page like a script file, like so:

[l:@chapteredarchive] 
  [c:l.is_first] 
    var title = '[v:l.comictitle]';
    var posttime = '[v:l.posttime]';
  [/]
[/]


and then include it from the page like
  <script type="text/javascript" src="http://yourcomic/jshax"></script>


you'd be able to use the variables you defined on that page to fill in the blanks. This should also be a significantly more stable solution, albeit it requires people to have javascript enabled (which tbf a lot of websites do for far more essential features, these days)
_______________________
hello
2 days ago, 8:18 PM #10
BeeMKay

Posts: 15
Registration date: 22nd Sep 2017
Location: Germany
Thank you, Kyo. I'll have to figure out how to include that, my first attempts weren't successful.
But I hope that the tidbit will solve things. It would be really cool to be able to create a page where you have listed all your latest projects&their latest updates, kind of like a resume of sorts.
_______________________
Demon Division (English Version) http://demondivision.thecomicseries.com/
Demon Division (German Version) http://demondivision-de.thecomicseries.com
Demon Division: Dwellers (English Version) http://divisiond-dwellers.thecomicseries.com/
Demon Division: Dwellers (German Version) http://divisiond-dwellers-de.thecomicseries.com
2 days ago, 9:02 PM #11
Kyo
family life
User avatar
Posts: 17838
Registration date: 6th Jul 2008
Location: Germany
can you link me to the page in it's non functional state? maybe I can figure it out
_______________________
hello
Forum > Layouts, HTML, CSS & Javascript > Showing just the latest chapter on extra page?
Pages: [1]