i'm on twitter

Tag Archive | "code"

Inline Images With Data URLs

August 11, 2010 No comments yet

This particular trick comes in very handy for the mobile platforms. Instead of linking to your CSS and your images, you can use this method to embed the images inline within the CSS. This keeps the browser from having to make multiple calls, thus speeding up the load time of your application. You can also [...]

Error Handling

August 11, 2010 No comments yet

In the world of the Internet, as a developer, we need to protect ourselves from prying eyes. One of the easiest ways a hacker can crack your code is if you tell them what they did wrong. For that reason, it’s important to suppress errors from the public. But, this doesn’t mean we should eliminate [...]

jQuery Tabs With Ease

July 3, 2010 No comments yet

As usual, I always need something special in jQuery. I’m always able to find plugins out there, but they never everything I want, the way I want it done. Each always falls short somewhere. It either limits my design flexibility, is buggy or is just flat-out bloated with way more code than is necessary. I’ve [...]

Database PHP Class

June 15, 2010 1 comment

I’m back with another chunk of code. This time, it’s my database class. I got sick of coming across classes that didn’t have everything I needed, or didn’t do it correctly. One of my biggest problems was an inability to nest query calls within another query result’s output.

jQuery Accordian without plug-ins & with a bit of design freedom

June 13, 2010 1 comment

So you have a design and you have decided you want to use a jQuery accordion. You start to layout your design and implement the accordion only to find out that your design is going to cause problems with the standard accordion plug-ins. The problem with the standard accordion is that they require the child [...]

(UPDATED 08-10-2010) Forms Class for easy and consistant forms

March 31, 2010 No comments yet

UPDATED 08-10-2010: I’ve cleaned up a lot of code and organized the code a little better. One major improvement is the passing of element attributes. You can now pass an unlimited number of attributes. If there are any you want omitted from the actual element tag, you can add it to the $attributes_not_allowed array. I’ve [...]

Load multiple JS files in one call

March 30, 2010 No comments yet

With this script, you can easily load multiple JavaScript files in one call. The main purpose behind this is to simply cut down on the clutter in your source code. The function can be called from anywhere and the files are specified in an array

jQuery “characters remaining” script

March 30, 2010 3 comments

This is a jQuery script for displaying “characters remaining” for input fields. It will look for any input element with the class “input” (or whatever you specify) and use the element’s maxlength attribute as the value to count against and update the “fieldName-counter” element. This is a very useful script for those occasions when you [...]


i'm on twitter