Skip to content

Commit

Permalink
Provide a working 404 by using markdown
Browse files Browse the repository at this point in the history
In order for the 404 to be picked up by jekyll/github pages,
it has to be in a 404.html file on the root. However, if the
file is named exactly '404.html', it won't be processed by
jekyll.

Rather, you have to provide a 404.md file, and specify its
permalink to be 404.html, which fixes the issue.

Working version at http://www.cazzulino.com/wrong-url.html.
  • Loading branch information
kzu committed Jan 17, 2016
1 parent ac85a31 commit a96fb59
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 10 deletions.
10 changes: 0 additions & 10 deletions 404.html

This file was deleted.

8 changes: 8 additions & 0 deletions 404.md
@@ -0,0 +1,8 @@
---
layout: default
title: "404: Page not found"
permalink: 404.html
---

# 404: Page not found
Sorry, we've misplaced that URL or it's pointing to something that doesn't exist. [Head back home]({{ site.url }}) to try finding it again.

0 comments on commit a96fb59

Please sign in to comment.