Skip to content
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

'.html' is hardcoded on Categories, Tags, and Archives #22

Closed
tshepang opened this issue Oct 6, 2013 · 25 comments
Closed

'.html' is hardcoded on Categories, Tags, and Archives #22

tshepang opened this issue Oct 6, 2013 · 25 comments
Assignees

Comments

@tshepang
Copy link

tshepang commented Oct 6, 2013

I saw this in templates/base.html.

@talha131
Copy link
Member

talha131 commented Oct 6, 2013

@tshepang that's because there is no other way to link to those pages. If you see the URL settings of Pelican you will notice you can customize the URL of article, tag or category page. But you cannot customize URL of categories and tags page.

That's why for article, you can use article.url or for tag tag.url.

But there is no variable tags.url for tags.html page. This is why I have to hardcode it.

Hope it explains the reason.

@tshepang
Copy link
Author

tshepang commented Oct 6, 2013

This issue must be reported on Pelican?

@talha131
Copy link
Member

talha131 commented Oct 6, 2013

Well it is not a bug.

It can be requested as an enhancement "Let users customize URL of archives, categories and tags pages".

@talha131 talha131 closed this as completed Oct 6, 2013
@tshepang
Copy link
Author

tshepang commented Oct 6, 2013

I don't fully understand the issue, but have created a workaround for now: https://bitbucket.org/tshepang/patches/src/7e7dc47c/elegant.diff.

@talha131 talha131 reopened this Oct 6, 2013
@talha131
Copy link
Member

talha131 commented Oct 6, 2013

Thanks @tshepang for sharing your solution. That's a good solution.

Question is how do we know what user wants. Take article URL as an example. User can configure it in the pelican-conf

ARTICLE_URL = u'{slug}'

Articles URL will not have .html in the end.

But user can also configure it to

ARTICLE_URL = u'{slug}.html'

The article URL will have .html in the end. So you can configure the article URL from pelicanconf.py.

Is there a way to configure Categories, Tags and Archives URL? No there isn't. So if we remove .html like you did, it will not work for those users who want their URLs to end with an .html.

Let me know what you think about it? Also feel free to ask if any point is unclear.

@tshepang
Copy link
Author

tshepang commented Oct 6, 2013

I am aware mine is an ugly work-around, that's why I'm not proposing that you include it.

@tshepang
Copy link
Author

tshepang commented Oct 6, 2013

BTW, I see that there's a TAGS_URL, TAGS_SAVE_AS and ARCHIVES_SAVE_AS settings. Wouldn't they help?

@talha131
Copy link
Member

talha131 commented Oct 7, 2013

@tshepang excellent find.

I need to ask Pelican team why we don't have CATEGORIES_URL, CATEGORIES_SAVE_AS, and ARCHIVES_URL. Something is amiss. I think we will be able to make a better decision after their clarification.

Thanks man!

@tshepang
Copy link
Author

tshepang commented Oct 7, 2013

koolnes

@talha131
Copy link
Member

talha131 commented Oct 9, 2013

This issue is related to Pelican

@tshepang
Copy link
Author

tshepang commented Oct 9, 2013

Yes, I've been following the discussion there.

@tshepang
Copy link
Author

Looks like this was already fixed in Pelican, only not documented?

@talha131
Copy link
Member

Related to getpelican/pelican#1225

@tshepang tshepang closed this as completed Nov 5, 2018
@tshepang
Copy link
Author

tshepang commented Nov 5, 2018

this went stale, so closing

@iranzo
Copy link
Member

iranzo commented Dec 3, 2018

Is this still the case? updates are from some years ago, but still I do see hardcoded archives, tags and categories while my pelican setup does use /tags/ vs /tags.html and likelywise for the others

@silverhook
Copy link
Member

If this still happens, we should address it IMHO.

On my website, it does seem to still be the case, so re-opening.

@silverhook silverhook reopened this Dec 3, 2018
@iranzo
Copy link
Member

iranzo commented Dec 3, 2018

I was trying to find a new theme that is responsive for mobile devices and doing initial 'simple' checks found this :/

@silverhook
Copy link
Member

@iranzo We have just expanded Elegant from a single maintainer to a community-driven projects and are currently picking up the pace again, so it’s a great time to get involved (see #173 for more).

I can’t promise we’ll be able to tick all your checkboxes, but if you see anything missing (or better yet, have a proposal/pull request), please do file an issue.

@iranzo
Copy link
Member

iranzo commented Dec 3, 2018

I saw it, but I'm not an expert in pelican (nor to talk about elegant), and so far just did some small patch some years ago for blue-penguin theme I'm currently using at my site.

Please do assign this to me as I think I can do it

@silverhook
Copy link
Member

silverhook commented Dec 3, 2018

I’m not even a coder and fixing stuff in Elegant (or any other Jinja-based theme) is very doable. So I’m sure you’ll rock it! 🤘

Hmmm, odd, it doesn’t seem like I can assign it to you, @iranzo. Can you try to assign it to yourself?

@iranzo
Copy link
Member

iranzo commented Dec 3, 2018

#186

@iranzo
Copy link
Member

iranzo commented Dec 3, 2018

I’m not even a coder and fixing stuff in Elegant (or any other Jinja-based theme) is very doable. So I’m sure you’ll rock it!

Hmmm, odd, it doesn’t seem like I can assign it to you, @iranzo. Can you try to assign it to yourself?

Probably as I'm not member of the project staff you can't do that (I had a similar issue with a project I own)

@silverhook
Copy link
Member

That makes sense. I don’t have a lot of experience with admining a project that has several outside contributors.

I’ll assign myself then, so it’s my fault if this doesn’t push forward.

The way I understand it, as soon as your pull request gets merged, you should be able to be assigned issues as well.

@silverhook silverhook self-assigned this Dec 3, 2018
@iranzo
Copy link
Member

iranzo commented Dec 3, 2018

@silverhook check https://iranzo.github.io/ and try the tags, categories, archives

@silverhook silverhook assigned iranzo and unassigned iranzo and silverhook Dec 9, 2018
@iranzo
Copy link
Member

iranzo commented Dec 9, 2018

I did submitted the PR, so it should be someone else to validate and merge :-)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

4 participants