Tag Archive for: Programming

The CSS-Only Webpage

Recently, while in the shower, I was contemplating how versatile CSS has become compared to how it used to be. I thought about how the appearance and even behaviour of a website can be changed so utterly as to be unrecognizable without its bespoke stylesheet. Then I had another thought. An idea really, and a rather silly one:

What if I were to create a webpage using ONLY Cascading Style Sheets?

Well, a stylesheet is somewhat of a code parasite; it can’t live independently and must always exist inside a host body in order to function (in this case, it’s the host head). So that’s what I limited myself to. The head, shoulders, knees, and toes of an HTML document with nothing else inside it. Save for the meta tags in the head, this document is completely barren. Without the sheet, you’d be faced with a completely blank white page with nary a stray bracket to its name.

But enough blathering about my nonsense! You want to see what I did, right? I mean, I can’t imagine you’d have read this far without being at least a LITTLE curious…

Anyway, here you go. Click the button below to view my experiment!

P.S. the background colour is #00beef. That made me chuckle.