It's OK not to use tools
signalvnoise.com
signalvnoise.com
Even hosted CMSes have a lot of cognitive overhead,
and the content is trapped away inside someone
else’s system.
Fair point, but I'd much rather explain to someone that I'm helping that they click this button over here, type in a box over there, and then click the big "PUBLISH" button than try to explain HTML or FTP to them.I've had a few occasions to help friends with the websites for their small businesses, and I've always tried to impress upon them that they need to be self-sufficient for their long-term web content updating strategy. I can't upload files for them every time they need to change some copy.
$10/month should not be a deterrent, especially given that you, as a professional developer should be able to bill out that hosting bill for a year in a single hour of your time. If you're helping out a non-profit, donate an hour or two of your time and $120 to help them build a new website, instead of ten hours of your time today, and then an hour of your time every month in perpetuity.
(The same applies in other domains, too - it's fine to rely on gcc's many -W switches, but be careful with its custom C dialect; etc.)
- It's easier for you, the savvy developer who groks the toolchain, because it allows structure and reduces repetition.
- It may very well be easier for the next person who wants to add a page or change some copy, because editing Markdown and running a couple (admittedly esoteric) commands is likely still easier than editing HTML directly.
- If the next person doesn't understand or like the toolchain, they can ignore it entirely and edit the HTML directly, which is no worse than if you didn't use a generator at all.
So yeah, you don't have to use tools, and yeah, CMS sites and compile-to-CSS is probably overused in the small-site market, but I think static-site-from-Markdown with vanilla CSS is a pretty sweet spot for this!
* No web UI. This may be a blocker for business folks who want to update a blog. This is a blocker for folks who are using devices like iPad's to update blogs (which is a huge reason why I moved away from things like Octopress and moved toward things like Ghost or Wordpress.) This may be a blocker for folks who don't always have the tools on whatever machine they're using at the time in order to generate the site.
* No imposed structure. It's easier to impose a web UI form that locks folks into certain workflows than it is to just give them a git repository with all sorts of stuff strung about, with no apparent structure other than the FS structure.
In terms of those downsides, I agree with you for larger sites, but not for the kind of really small sites the OP was talking about.
I've written blogging software that did just that. Every time the author edited/added something in the web UI (which saved to a db), it just re-'compiled' the particular pages.
I suppose you could use the static generator for the initial build and then throw it all away yourself, but that's basically the same as not using it at all.
Server side includes are built into both Apache and nginx, and are a very mature technology, so you don't even have to worry about that. (And lots of ISPs, including Dreamhost, support them. Notable exception: S3.)
True, but still: there is still a lot of wilderness to get lost in between certain future needs and possible future needs. Realizing you need to go back and fetch your bat belt to cross a bridge as you come to it costs time; but so does hauling a million tools which you could have needed, but actually didn't end up needing that day. We all have our anecdotes, but none of them invalidate the one of the author.. if he says he's happy with his work, and his client is as well, I will believe it.
"Perfection is achieved, not when there is nothing more to add, but when there is nothing left to take away." (Antoine de Saint-Exupery)
To read that as "let's go back to before anything existed, and stay there", is missing the point. Likewise, when someone says that sometimes it's okay to bring a walkman, they are not saying orchestras should not be a thing; just that, say, when you are jogging and want to listen to some music, it's more practical to bring a portable audio player and headphones, than have a orchestra/band run beside you. While that is always the coolest option, it is not always the most practical, and it can even seem a bit tacky. Sometimes, just sometimes, less is more.
I was facing exactly this problem on a static HTML website a few months ago, and was pleased to discover that two Google queries and five minutes' work left me with a functioning SSI.
I've used SSI and I don't wish to use it again. It isn't the same as a static page, and is too underpowered for me to want to use it for a dynamic page.
It reminds me of files that don't contain a well-formed html fragment. Stuff like
<!--#include "header.html"-->
<p>Hello</p>
</body>
</html>
Oops, did I just remember the proper syntax for SSI? Guess I might not have forgotten it like I intended to. :PAlso server side includes are using a second language inside a first language without any introduction to the second language. No mention of them here: http://www.w3.org/TR/html401/
Edit: I didn't quite remember it right. It's <!--#include virtual="header.html"-->
It isn't in the file extension, the extension is just .html.
"include" by itself is the tenth result on google. "include virtual" and "include file" (without quotes) have SSI in the top results. But not everyone is going to google that.
With C most knows there's a preprocessor. That could be true with HTML and Server Side Includes, but it isn't.
Searching for server side includes on google works fine.
And the comment-formatted "#include" directive seems pretty clear to me.
The phrase "server side includes" doesn't appear anywhere in the "#include" directive. I'm talking about what could be gleaned from the code alone. And again, if they put file or virtual in their search term, they get the result. I just don't expect all web developers to do that.
To address your last point: the #include language seems simple but it doesn't explain why it's happening. It would seem like black magic to someone who thought their host was just sending files to the client and didn't know about SSI.
Logically, a small website should be built with static HTML and CSS. So why build an overly complicated infrastructure with a web application front-end and a database back-end (which needs to be regularly maintained) just to display a simple website?
In many cases, WordPress became the hammer looking for anything that resembles a nail.
There is a large percentage of decision makers who want to be able to update their own sites, despite barely being confident enough to use Microsoft Word. In actual practice, the odds that these decision makers will ever actually update their site is nearly 0%. However, despite this, they still want the capability. If I were to show them static HTML/CSS, I'd starve.
For me, Wordpress gives me an interface that I can show these people before they decide to hire a quack who uses Wordpress for everything.
I've sometimes thought of a business model where I'd do content updates within 24 hours, but that just seems insane.
You could spend a lot of time thinking and examining requirements and come to the conclusion that a static site with very minimal but carefully designed styling would be an effective solution.
But it's hard to ask for thousands of $ for that with a straight face when the competing bidders are offering CMSs , iphone apps and facebook integration for the same price.
Then I go to my browser, hit F5, and presto, my change is displayed.
Ahhh, and I don't even use CSS! Only html5.
I use the following tags: h1, h2, h3, h4, p, ul, ol, li, br, strong, and i.
I use © and &
And I let the browser render as it wishes.
Famous last words. The day when it's not an easy fix, you're stuck with bad code live in production affecting all users until someone can fix the bug. Worse, the only way to verify that the fix works is to check your assumptions against the live system aka a nightmare. Of course, none of this matters if your site is a personal blog or something that doesn't affect anybody's business, but nothing really matters in that case.
I've found it effective at abstracting away browser differences.
"Actually, could you remove the facebook link from the header and put it on the footer"
> Why do we need a CMS for an 8-page site?
"James might need to make some changes in the future, don't worry only the edito ... HTMWhat ? FTPWhat ?"
> Let's add Sass and a grid system ... Regular old CSS can do the job just fine.
"This needs to run on IE8"
> They want to get stray animals adopted, not fuss around with website stuff.
Exactly.
This assumes the site has a header and a footer. The author just specified navigation. Maybe the facebook link is only on the home page. Is that a real problem?
> "James might need to make some changes in the future, don't worry only the edito ... HTMWhat ? FTPWhat ?"
Then someone can help them get it set up, when that happens, and it will be easier for the person helping James to get them set up with whatever tool James is comfortable with. It's hard for people to learn skills they don't need to use right away.
> "This needs to run on IE8"
Depends on the tools that are being considered, some new tools like ZURB Foundation (which is one way to use Sass) and Angular don't support old browsers, for reasons that are valid for a web app but not for a simple website.
man diff
man patchWe shouldn't use newer tools just because we like new, shiny technology. And we definitely shouldn't push them on our non-technical customers.
But! Saying that modern tools are not more convenient is wrong. Copy-pasting the same change to 8 files is not an improvement. It's not an improvement both practically, since you will mess up on the 18th change you're required to make. And it's not an improvement in reality, because in reality the people who don't use something to abstract this problem away don't do it because plain HTML/CSS is better, it's because they don't know how to solve this issue, or even that they need to solve this issue.
The technical world is better because we assume that you won't have to hand-edit and hand-apply changes in the way the article talks about.
And lastly, anyone thinking that WordPress is a problem is simply mistaken. WordPress is one of the most popular systems for getting real-life people to be able to create and post content to the web. The kind of people who don't have a clue what HTML is, and who couldn't care less.
For these people, and arguably for most people who want a quick web site with a nice-looking theme and easy ability to create and edit content, then WordPress is the best option by far. Even knowing many other technologies and being in general a power-user, I still use WordPress extensively. There's no easier way to get a decent looking site online.
1, They let the site go stagnant again like their previous site. 2, They want to build more on top of their site.
I always build a site like a client is going to come back to me for more work. I never work on the expectation to build and forget.
In most cases, the client ends up coming back to me for more pages. I've generally built this in a CMS so I charge 1 hours work for something that takes me 30 minutes to sort out for them. There is a client service there where I am doing them a service. I make 30 minutes profit per page (at a min charge of 1 hours work at a time) and everyone is happy.
The beauty of this method is that I am not coming back to a site in a year and wondering how I built it. Did I put navigation on every page? Were there differences on some pages?
I say Yes to not over complicating, I say No to not over complicating at the expense of making it complicated again for yourself to modify in the future.
EDIT: Typo
Can you honestly say you haven't built a site before that you wish you had built differently? I know I have.
These regrets make us make better decisions in future and to that end I always plan for bigger.
For me, a static site generator is the bare minimum.
I think our culture has put too much of a taboo on copy and paste. It's not the end of the world if you're careful about it. Ideally, yes, you'd have it defined in a single template which then assures you that all pages are identical.... but what happens when the next guy comes and doesn't understand how the templating system works? It may end up costing your client a lot more money because the guy has to spend time figuring out your specific brand of templating, making sure he has the tools to work with it, etc etc. As opposed to simple copy and paste in plaintext, no tools, just content.
If a user requests "/foo/bar/baz" you have to allow your webserver to stat "/foo/bar/baz/.htaccess", "/foo/bar/.htaccess", and "/foo/.htaccess" which can be a significant performance hit.
SSIs have similar issues, parsing all files on the off-chance there is some magic that will be required.
You never know when your site is going to be posted to hacker news, or similar!
I had intended to use a content management system at some point but never got around to it.
As these are common tools there's no cognitive overhead for developers and it can still be automated for users.
So what if I have to repeat the navigation markup 8 separate times? It’s not that hard. We used to do it for much larger sites!
I would still be tempted to use a static site generator for it. You can always hand over the compiled output for the next person to maintain.Other tools like sass/less, I would be less tempted partly because it's slightly harder to get human maintainable output (though the argument of a small site counters that too!)
It's kinda of a static hosted hierarchical website generator CMS (if you like these pedantic names):
https://github.com/fiatjaf/fiatjaf.github.io
(and you can access the CMS at work here: http://fiatjaf.github.io/edit , just ignore the password thing)
The idea is that you can create `docs`. Each doc you render itself to a page. Each doc is a JSON object including
- `title`, a title to be findable and nice, and to be displayed on the CMS, but not strictly required, as docs also have ids.
- `text` (something that will be displayed as is, or after some markdown rendering)
- `data` (field in which you can put structured data such as JSON, YAML, CSV, suggestions accepted) and do something with it later
- `parents` (a list of ids of the parents of this element, parents are used for generating URLs such as /parent/son/grandson and some other relationships -- like parents can receive its sons as data instead of the data at the `data` field)
- `kind` (a field that will be used to reference a `processor` and a `template` to render that data later)
- any other attribute you want, included using the traditional `yaml-frontmatter`, that can be used later for processing or display
In the rendering process each docs is passed to the processor referenced by its kinds and then to the template referenced by its kind and the HTML is generated.
this way will just increase cost for his/her client down the road. Use even a super simple templating system (even if it is just including header/footer).
sure, using WP is overkill. but this is just silly to have actual plain .html files...
plus in a url http://example.com/about-us.html doesn't look as nice as http://example.com/about-us
(something like mod_rewrite could fix this, but if he/she is copy/pasting headers/footers i doubt that would be implemented...)
Tools give some people too much rope ...
One of the saners reasons is to avoid broken links
but I see broken links with with clean urls all the times. So don't think that is a good reason either.
http://www.html5rocks.com/en/tutorials/webcomponents/imports...
It seems these days you need a whole Django/Wordpress/etc app for even the simplest, static content.
Why is there this group of people fighting against innovation, against experimentation?
For your client you can do whatever you want, but you should strive to make your code manageable at least.
> Remember when the web was damn simple? It still can be. It’s up to us to make it that way.
Over a decade ago, I used java servlets, with XML and XLST. It was not simple.
Login, edit a page - you can even keep the edit url as a bookmark, preview and publish.
As compared to teaching her about FTP, opening files in a text editor, and editing HTML/markdown.
Updating pages through a CMS is also easier to an end user, than editing text files.
http://developmentseed.org/blog/2012/07/27/build-cms-free-we...
see also: http://prose.io
I do not think Saas means what you think it means.
Edit: I made a reading mistake
I do not think Sass means what I think it means.