Recent Articles

One night stand framework

I have always been a big fan of JavaScript. The moment I discovered that I could use alert() to debug, I fell in love with it. That was many years ago, when I was still telling people to fire up internet explorer, notepad and get started. At lot has happened since. I find myself more reluctant to just recommend JavaScript to new developers now.

Don't make things too complicated

There is an advantage with ignorance. Ignorance not in the sense of name calling, but more toward when you are new in a field. Most people that just get started in web development want to change the world. That is a good thing. But then they get stuck somewhere and ask the more seasoned developer for help, their dream is crushed.

Why you should publish your projects

Working on a project for a long time but afraid to publish it on the web? Don't worry you are not alone. The majority of us have projects that are resting in the tomb we call repository. Just when the project is almost ready, we lose interest. No, we don't lose interest. We find another project to work on so we don't have to deal with the problems of publishing.

In pursuit of happiness: Job Security

In December of 2010, I was running dangerously low in funds. I hadn't found work in a while. A while being weeks. I was freelancing. My main source for income was Craigslists. Some gigs offered 200 dollars for impossible jobs, some were wittier and offered 20 dollars an hour for 3 hours of work for a 40 hours long project. I couldn't live in this unpredictable pattern of inconsistent jobs. I had to get out. I had to find a nice secure job.

The most important skill you will learn in school

In my brief time in college, I have learn a few skills that allowed me to launch myself into a career. I have learned programming and started working in the field in a short time span. There are lot of practical things you can learn and use right away. But if I have to tell you which subject was the most important in my career, no doubt it will be Art.

What are you working on?

If your answer is a derivative to "it's complicated" then you have a problem. I recently contacted the owner of a website that I found fascinating. He posted a few things on his blog then went silent for a long time.

Creating an online pamphlet

In the past few years, I been have working on creating and maintaining websites. I grew tired of it. Not because the task is boring. I love programming. I would do it just for fun. But the reason why I create website has changed. Maybe it's because I grew up, or maybe it's just that I don't like creating the same thing over and over. One thing for sure is, I will not be working on someone else's poorly executed idea. I will work on my own poorly executed stuff.

Switching to open office plan killed more than productivity

When I started working as a web developer in a big company, I had my own space. I had plenty of time to myself and privacy. We were each surrounded by 3 walls which formed a cubicle. If I had to question for the lead developer, going to his cubicle seemed like entering his house. Most of the time I would just send him a message on instant messaging, but on some rare cases I would come to his office/cubicle/private quarters.


JavaScript Tips and Tricks

Calling a function out of scope

With the advent of jQuery, coding in JavaScript became accessible to almost everybody. But with it came some very fundamental errors that could have been avoided if the person read the very basic of java script. Users define…

Get computed style

Sometimes you want to get the width of an element, and the obvious way of getting it does not work. element.style.width; // (empty string) Yeah, I know it should be this easy but it is not. Instead we have to get the comp…

Accessing URL parameters in JavaScript

I have worked with PHP extensively and it is very convenient to have all the URL parameters automatically assigned to the global array $_GET. Here is an example: http://www.example.org/?foo=bar $_GET['foo']; // bar I wish …

Calling a function that has no name

You can make use of recursion easily in JavaScript. Let's try it with factorials: function factorial(num){ if (num < 0) { return -1; } else if (num == 0) { return 1; } return (num * fa…

Making fast cross-domain requests when the browser is leaving

There are times you want to make a very quick web request and don't care about the response looks like. It is possible to make requests using Ajax, but we still get a response. One trick you will see many people are using is…