hi there.
i’m new to zola and a bit confused after some experimenting.
[zola 0.9.0]
the problem:
i want to publish the slides of my course for my studets.
simple task: on every site you have some words/ media and a next-link
now i thought i create a section with a page per slide:
|---talk_1/
| |---slide1.md
| |---slide2.md
| |--- ...
|
|---static/talk_1/
| |---doorbell.jpg
| |---xenakis.mp3
when building i get a problem with the (relative links) assets for each slide
---talk_1/
|---slide1/
|---index.html
|---slide2/
|---index.html
|--- ...
|---doorbell.jpg
|---xenakis.mp3
because the html suggest that the files would be within the slideX folder.
/talk_1/slide24/xenakis.mp3
i wrote a short code for the media embeds. for example:
/template/audio.html:
<img alt="{{alt}}" src='{{src}}'>
in the slide.md file i say:
{{ image(src="./doorbell.jpg" alt="doorbell") }}
the next link also doesn’t work with this setup.
in each .md page i define a
[extra]
n = <next slide>
in the template the link is created:
{% if page.extra.n %}
<div class="next">
<a href="./slide{{ page.extra.n }}"></a>
</div>
{% endif %}
here i have the same problem that the rendered link looks like:
<a href="/slide1/slide2/index.html">next</a>
this works fine with zola serve
but the build doesn’t work…
is this a bug or a feature?
assumption: wrong approach?
although i would expect zola to ‘correct’ the links i’ve been looking into the pagination thing because it seemed to be actually what i want but the documentation is not explicit enough for me.
Two things can get paginated: a section and a taxonomy term.
how do i paginate a section?
the documentation only tells me what happens if a section already is paginated:
A paginated section gets the same
section
variable as a normal section page minus its pages. The pages are instead inpaginator.pages
(the classic problem of teaching/knowledge transfer: it’s hard to forget what one already knows.)