Only 90s Web Developers Remember This

Only 90s Web Developers Remember This

Have you ever shoved a <blink> into a <marquee> tag? Pixar gets all the accolades today, but in the 90s this was a serious feat of computer animation. By combining these two tags, you were a trailblazer. A person capable of great innovation. A human being that all other human beings could aspire to.

You were a web developer in the 1990s.

There are more nostalgic examples of how we used to do things back in the day …

Searching CakePHP pages

CakePHP framework comes with the default PagesController which is an awesome out of the box way to build a website of mostly static pages.  There is one rather annoying limitation though – no search option.  If you need a website of mostly static pages with search functionality, you are out of luck.  I spent a good chunk of time Googling (searching, eh?) for a solution and even talking to people in #cakephp IRC channel.  The best alternatives, it turned out are listed in this StackOverflow answer:

There is no built in way to search static pages as they are just files on disk.

You have three options

  • Build a model to hold the data somewhat like a CMS so you can use mysql search.
  • google search for sites
  • the more hacky approach of reading the contents of all the pages and using preg_match() or similar on the contents to find matches.

The first option is probably the best depending on your use case. The second option is the easiest if its public facing content. The third option is a horrible idea

Since I need the solution for a public facing website, it looks like I’m gonna go with Google Custom Search Engine option.

John Resig : Write Code Every Day

John Resig, of the Khan Academy developers and the author of jQuery JavaScript library, ran an interesting experiment on himself – write code every day.  The rules were very simple:

I decided to set a couple rules for myself:

  1. I must write code every day. I can write docs, or blog posts, or other things but it must be in addition to the code that I write.
  2. It must be useful code. No tweaking indentation, no code re-formatting, and if at all possible no refactoring. (All these things are permitted, but not as the exclusive work of the day.)
  3. All code must be written before midnight.
  4. The code must be Open Source and up on Github.

Some of these rules were arbitrary. The code doesn’t technically need to be written before midnight of the day of but I wanted to avoid staying up too late writing sloppy code. Neither does the code have to be Open Source or up on Github. This just forced me to be more mindful of the code that I was writing (thinking about reusability and deciding to create modules earlier in the process).

And he got some very interesting results, not to mention – a whole lotta work done.

While I’m not the biggest fan of productivity boost experiments, this one does resonate with me.  I’ve done a similar one when I was learning photography.  I decided to take at least one picture every day with my camera (no mobile phones), with no automatic settings.  Some days were better, some were worse, but I manage to run it for about four month and I couldn’t believe how much better I got  – I was still a noob, but the difference between the first days and the last days was huge!  The routine, once you get into it, is a very powerful tool, apparently.

For about a year or so now I’ve been avoiding any side projects, trying to recover from a previous burnout.  But now, slowly, I am looking into ways to get me back on tracks.  This approach looks interesting enough for me to consider.

logstash – a tool for managing events and logs

logstash

logstash is a tool for managing events and logs. You can use it to collect logs, parse them, and store them for later use (like, for searching). Speaking of searching, logstash comes with a web interface for searching and drilling into all of your logs.

It is fully free and fully open source. The license is Apache 2.0, meaning you are pretty much free to use it however you want in whatever way.

logstash is now a part of the Elasticsearch family!