A few weeks ago, I was looking for a new desktop wallpaper but couldn't find a great source of wallpapers. Some websites offer giant selections from which I could choose but the quality wasn't that good. I decided to buy the domain http://wallpapermonthly.com at that moment with the hope of building and curating a website with a monthly selection that favors quality over quantity. I don't expect to select more than 5 items a months. This happened during the time I was supposed to revise for my exams so I couldn't act on it but I was still very excited.
After I took my exams, I allowed myself a lot of time to rest and one day — actually on my birth day — I thought it would be fun to build a website in a day. The general idea and the domain were already here, but I didn't know how the website would look like or work. Even if I only had a few hours, I didn't want to rush it and took some time to think about it and put my ideas on paper.
The idea is to provide a monthly selection of wallpapers. I don't want it to be complicated. Just display a few images in one post per month. I want it to be very simple, with no unnecessary information. It must be easy to navigate through the months with newer and older links. There also should be a simple archive page with only links to each month. I also don't want to have any problems with copyright information, so I will only host 800px large preview files and offer a download link to the author's page unless they ask me to host the hi-res wallpaper. People should also be able to submit their work or work that they find worthy of sharing with our readers.
Which CMS ?
It was out of question to build a static website of course. Wordpress is too heavy with and I wouldn't use half of its features. In the last year, I've become very familiar with Kirby CMS, a file-based CMS that requires no database. The good thing with Kirby is that it is so flexible that you can do almost everything with it.
That part wasn't that hard because it was clear in my head how the website would work. I only used my pen and paper, sketched something in 5 minutes and designed it directly in the browser.
I am aware that the interface design is far from perfect, I plan on improving it without affecting its simplicity.
Once again, everything was clear in my head so that wasn't very hard. I'm going to explain the general structure of the kirby-powered website.
In the content folder, I created 5 folders :
- error : 404 "not found" page.
- entries : front-page where the magic happens; all the subpages consist in monthly entries. Envision it as a blog with monthly blog posts.
- archives : generated page with all the links to previous entries.
- about : display the purpose of the website, a colophon.
- contact : to submit an entry.
The entries directory acts like a homepage. In this folder, there is a folder for each month named with this pattern : yyyymm - name (y: for year, m: for month) and that contains an entry.txt file redacted in markdown with a title and a date only. It also contains the previews for each wallpaper named with this pattern : nn - name.jpg (nn being the number that represents in which order I want to display the images). For each image, there is a text file named nn - name.jpg.txt with the metadata for each image : title, author, link.
The magic happens in the template
With kirby, you can create templates for specific pages. For this you just need to use the same name for the .txt page and the template file.
The entry template is easy to understand and to build. For each image contained in the entry folder, kirby should create a list element that contains the image followed by the title with the link to the wallpaper and the author's name. If there is an older or newer entry, a link to this/theses entry/entries should be created.
The entries template fetch the latest entry's information and displays a link to the previous entry.
I don't even use an administration area, it all happens with a text editor and an FTP connection. For each month, I just have to create a new folder yyytmm - month year, with a text file entry.txt containing the name and date. I then download the wallpapers, resize them and rename them. For each wallpaper I create a .txt file with the same name containing the title, name and link to the wallpaper. I upload it. I'm done.