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

Add unique id for post #45

Open
jwillmer opened this issue Jul 17, 2017 · 2 comments
Open

Add unique id for post #45

jwillmer opened this issue Jul 17, 2017 · 2 comments

Comments

@jwillmer
Copy link
Owner

The idea is to set a unique id in the YAML header that is used in the post URL. If you change the title of the post later it does not matter since we only care about the post id. This is search engine and user friendly and an improvement to using redirects if you change the post title.

Example Header:

layout:         post
title:          "This is my title"
id:             5465456
date:           2016-04-06 00:40:00 +0300
author:         jwillmer

Example URL's:

https://site/blog/id/title
https://site/blog/5465456/This-is-my-title
https://site/blog/5465456/This-is-a-different-title-to-the-same-post

Permalink in _config.yml:

permalink:        /blog/:id/:title

Everything after id will be ignored for redirecting to your post.

On-Hold since we need Jekyll and GitHub to support this.

@jwillmer
Copy link
Owner Author

Referencing issues:
jekyll/jekyll#3725
cauerego/cauerego.github.io#3

@joeyhoer
Copy link

joeyhoer commented Aug 2, 2018

I think a setting to allow developers to customize the file output directory structure within Jekyll independent of the permalink could accomplish the same thing. Developers could then program The server to negotiate the filesystem and server the correct files.

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

No branches or pull requests

2 participants