-
Notifications
You must be signed in to change notification settings - Fork 953
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Custom URL templates. #635
Comments
Is that a duplicate of #624 or are there patterns other than ones with dates? |
This is barely related to #624. Although it would be cool to be able to have a post at |
Adding date bits in the URL is probably not going to happen anytime soon (if it ever happens). I don't really understand the docs for categories in that link though:
Zola doesn't have categories so how would that handle multiple taxonomies (multiple tags and an author for example)? Tons of duplicate content? |
Why? It’s quite an important feature, in my opinion. Nearly every other CMS has some way to do this.
It’d be up to the user. They could decide what gets included and where. Tags,
This means that if it has the category |
So I've been reading all the related issues about the date in url format, and I'm wondering if there's a good reason to not add this feature? I'm not strongly inclined either way as I'm new to this, but it seems like a standard thing to have. @Keats, do you think the idea is inherently a bad one, or would you say it's just no one wants to implement it right now? If it's the former I'm curious as to the reasoning behind it. |
I left a long comment explaining why there won't be date URLs parameters but I can't remember where I posted it - it was at least a year ago. The main points were:
As for the other kinds URL template, the one I feel would be helpful is something like |
I am not sure if this bug is the right place or not, feel free to tell me to open a different issue. I have an existing site I'm porting over, and I need pages to end in |
Hugo has the concept of "pretty urls" for that: https://gohugo.io/content-management/urls/#pretty-urls and you can disable it by having There is no way to do that in Zola currently but it shouldn't be too hard to add. If you can create another issue to track that specifically that would be great. |
I thank that does deserve its own issue, I have run into the same issue trying to convert my blog |
Fair enough, this is what PR are for ^^
I've never though of this. Can't something be done by using
I would expect this if I enter in the archive section of the site, not the live section. But I might be only me. @Keats Shall someone tackle this anyway? If you agree, I'll have a look as I need it to migrate my blog over Zola :) |
After more thoughts on it, I don't need it ^^ |
Not going to support that, closing. |
@Keats I feel strongly that this should be supported. Is there any chance this could be re-opened (or a PR accepted, even if this issue is not re-opened)? I specifically want this because I have ported over a website with a lot of blog posts where some of the paths would clash if the date wasn't part of it. Currently, this is solved by every blog post having an explicit |
Honestly I think having an option to integrate the date in the path would suffice, no need for full blown custom url patterns. |
I have Hugo config like: permalinks:
post: /post/:filename/ which people can access the URI seems zola does not support this, which block me from switch to it. |
Same here. The basic requirement when porting a site is the maintance of the old URLs. A site that was not "fortunate" to adopt the default Zola URL pattern previously will break ALL URLs. Of course, it could be achieved by implementing If the scope of the project is to create small sites, ok. If the selling proposition is to manage large content pools, it is a must, IMHO. A use case is the automatic content creator (like documentation a software API) that creates thousands of .md files and then delegates them to an SSG to build the site. With proper URL configuration, the pages could be presented in a flat structure like a wiki or very hierarchical. Some advantages:
At least open the door for someone to implement it in a PR. |
Feature
Problem
Some people are migrating from previos sites, and we want to make this as easy as possible for them. Other people want to future proof. A few just want to look different.
All of those people could use custom URL templates. For example, if a user was migrating from a blogger blog, their url would look like
/YYYY/MM/title-slug.html
, or a Jekyll blog might look like/YYYY/MM/DD/title-slug.html
. However, all Zola pages are forced to be/collection/title-slug/
. This makes it hard to migrate, as the URL scheme is broken.This could be solved by allowing them to use a custom URL template, possibly stored in the format discussed in #634.
This also helps fture proof, as a club or a project may want to post multiple posts with a title like "this week's updates", but if there is no date, or hash, or some other thing that would change, then the URLs would clash, and they would be unable to post.
The text was updated successfully, but these errors were encountered: