-
Notifications
You must be signed in to change notification settings - Fork 484
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 front-matter options to hide post meta and actions. #399
Conversation
This makes custom 404 error pages look more clean (#327).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
great!
docs/user.md
Outdated
@@ -612,6 +612,8 @@ gallery: | |||
- http://i.imgur.com/o9r19kD.jpg "Dubai" | |||
- https://example.com/orignal.jpg https://example.com/thumbnail.jpg "Sidney" | |||
comments: false | |||
hideMeta: true |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
use meta
and actions
variable names to have the same code style as comments
. so update your if condition with (post.actions === undefined || post.actions)
to still show the meta and actions if variables are not declared in the front-matter.
docs/user.md
Outdated
Finally, you need to tell your server to use `/404.html` (which Hexo generates out of `404.md`) as your default 404 error page. Here are tutorials for the most common web servers: | ||
|
||
- [Apache](https://www.digitalocean.com/community/tutorials/how-to-create-a-custom-404-page-in-apache) | ||
- [Nginx](https://www.digitalocean.com/community/tutorials/how-to-configure-nginx-to-use-custom-error-pages-on-ubuntu-14-04) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also add the link for Github pages tutorial: https://help.github.com/articles/creating-a-custom-404-page-for-your-github-pages-site/
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
May worth to reference Amazon Cloudfront/S3 custom errors too: http://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/custom-error-pages.html
I've updated this PR |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
This makes custom 404 error pages look more clean (#327).
Configuration
Changes proposed