Reusability and the DOM
Aug/081
I consider my PHP to be well-written and at least somewhat re-useable (as much as any code can be), but my javascript? Not so much.
Is it because I haven’t chosen sides in the framework wars? (dojo, jquery, prototype, yui…) Is it because javascript has evolved beyond it’s display-logic roots into a “full-service language”, without also having it’s documentation mature? Is it because so many ‘designers’ don’t know how or why the id & name of form fields can be different?
Maybe it is due to the hooks provided by the DOM? Each page can have hundreds of unique hooks, and you need to go into the project with a sense of structure & organization, otherwise you’ll be including 20 javascript libs on each pageload.
And what about decoupling? I see people selecting elements based on their classes all the time. I think that’s ok if the class is structural in nature, but is it right to select on presentational classes?
Maybe it’s about standardizing the mapping between the database, the HTML, the CSS, and javascript, so that there’s consistency, predictability,reliability, and the potential for a whole lot of process streamlining via frameworks & integrated development environments.
Or does something like this already exist? Have I missed the boat?
Leave a comment
No trackbacks yet.
PHP & AJAX
Aug/058
WOOT! This is entry #700 in my blog!
Given that I don’t post too too often, that’s pretty amazing ![]()
And now, on with the show…
Sorry Mom, but this post is mainly for php/web developers.
Today I’m going to mention some of the best stuff I’ve found lately.
Venkman is a great/complex Javascript debugger with breakpoints and stepping etc. Built by the Mozilla Foundation. Yes, it’s named after the Ghostbuster “Peter Venkman”, as played by Bill Murray.
Frustrated that there’s no Safari Javascript Console like the one Firefox has? Guess what! There is one! It’s just not easy to find, or turn on. Here’s how to do it:
- Type this line into terminal: defaults write com.apple.safari IncludeDebugMenu 1
- Start Safari
- In your Finder, to into the Applications=>Utilities Folder
- Drag the one named ‘Console’ to your Launch Bar
- Click it, and Voila, you have a Javascript Debug Console
We develop primarily for IE6 (ack!) at work, but since I’ve started implementing AJAX stuff they have asked me to make everything compatible with IE6 Windows, Firefox Windows/OSX, and Safari OSX. Fun fun fun!
Ever wanted an EASY way to validate form input?
Have it now. Have it easily. Check out The Form Assembly. Their killer “wForms” is an unobtrusive javascript extension that adds commonly needed behaviors to traditional web forms. It is cross-browser compatible, and does not require any knowledge of javascript to be used.
Follow the following link to know more about unobtrusive javascript
Tired of Internet Explorer Puking on CSS?
Dean Edwards has created an amazing javascript that you simply include in the head of your page, and it helps IE along whenever it feels a bit geriatric. He’s calling his script “IE7″. IE7 version 0.8 is now available for download.
As I’ve been doing a bunch of AJAX (asynchronous javascript and xml) lately, I have found some great AJAX resources/libraries. Here they are:
- Prototype: The premier AJAX library, as used by Rico, RubyOnRails, Scriptaculous, and many more. No documentation, but otherwise very sweet.
- script.aculo.us: A javascript class which extends Prototype, giving you more features. Amazing & easy to use. Slightly more documentation than Prototype.
- Rico: Mind-bogglingly awesome javascript library that will change everything you think about javascript.
- SAJAX: The simplest PHP/AJAX library I’ve found. It’s what I’m using at work.
Check out this cool Liquid Lens that will allow glass-lens quality optical zooming WITHOUT needing to extend or retract anything mechanically! It works like the human eye, or a glass of water that happens to magnify the newspaper sitting beneath it. Coming soon to cameraphones near you!
How many times have you needed a good, modifiable, easy-to-implement wysiwyg textarea editor? If you’re anything like me, the answer is many, and the number of times you’ve found one is zero, especially if your emphasis was ease of modifiability. Hunt no more, there’s now an open-source FREE alternative named TinyMCE and it looks pretty great… and FREE!
Are you a php developer? Do you want to be up-to-date on all the cool stuff going on in the php world? Do you want to get Zend Certified? If so, and if you have a lot of extra money laying around, you probably want to check out php|works. It’s a php conference happening in Toronto in mid-September. Registrants can write the Zend PHP Certification exam for free ($200 value), which is probably why it costs nearly $800 to register.
Many of the bigger names in PHP will be there, including:
Rasmus Lerdorf (the creator of php)
George Schlossnagle (guru – creator of APD/PDO/Serendipity)
Chris Shiflett (php security guru)
John Coggeshall (guru & Zend Technologies employee/consultant)
Wez Furlong (guru – prolific PEAR/PECL contributor & creator of PDO)
Too bad Harry Fuecks isn’t on the list. Oh well. Can’t win’em all.
I’m excited about going!!!
What should I wear???
Last, but certainly not least, a friend of mine recently built a really cool job search engine and named it JobBlender.com. What it does it aggregate listings from Workopolis, Monster.ca, and HotJobs, and give you search results from all 3 on a single easy to use page. You should try it
-
11:15 pm on August 18th, 2005It doesn’t matter what its about, i love hearing about what you are interested in! I think Harry Fueks was on tv a few weeks ago, but have to be honest I wasn’t paying much attention. I think if you get a few hours you could design a very cool shirt. White dress, elegant, then add whatever php jargon you wish in a type design that looks like a tuxedo front. Well perhaps i am a bit odd, it was just a thought, I am so glad to hear that you are liking what you are doing at work, that is , to coin a phrase ” sweet ” hugs
-
12:41 pm on August 20th, 2005Voodoo ether:well send your blog into space so E.T. can read your posts,check out http://bloginspace.com.
-
6:51 pm on August 21st, 2005good idea with the jobblender.com
a much better one is at http://www.petersnewjobs.com
-
5:34 am on August 22nd, 2005Is job blender open source? i’d like to do something like that in the UK.
- J
-
8:55 pm on August 22nd, 2005“I’m excited about going!!!
What should I wear???”uh… who are you and what have you done to derek?
-
11:25 pm on August 22nd, 2005http://www.jobblender.co.uk coming soon
-
4:37 am on August 23rd, 2005So JB, are you actually going to write that? or are you just foolin, if so, then i could really use it right now for all the irish job sites (Job Blender.ie) as im currently looking for a job in ireland. Well, you seem so keen to blend jobs, i dont wanna steal your thunder
-
10:30 am on August 23rd, 2005Derek is still Derek.. he needs us to help him choose between his Spiderman and Darth Vader costumes
Leave a comment
No trackbacks yet.
-
11:15 pm on August 18th, 2005It doesn’t matter what its about, i love hearing about what you are interested in! I think Harry Fueks was on tv a few weeks ago, but have to be honest I wasn’t paying much attention. I think if you get a few hours you could design a very cool shirt. White dress, elegant, then add whatever php jargon you wish in a type design that looks like a tuxedo front. Well perhaps i am a bit odd, it was just a thought, I am so glad to hear that you are liking what you are doing at work, that is , to coin a phrase ” sweet ” hugs
-
12:41 pm on August 20th, 2005Voodoo ether:well send your blog into space so E.T. can read your posts,check out http://bloginspace.com.
-
6:51 pm on August 21st, 2005good idea with the jobblender.com
a much better one is at http://www.petersnewjobs.com
-
5:34 am on August 22nd, 2005Is job blender open source? i’d like to do something like that in the UK.
- J
-
8:55 pm on August 22nd, 2005“I’m excited about going!!!
What should I wear???”uh… who are you and what have you done to derek?
-
11:25 pm on August 22nd, 2005http://www.jobblender.co.uk coming soon
-
4:37 am on August 23rd, 2005So JB, are you actually going to write that? or are you just foolin, if so, then i could really use it right now for all the irish job sites (Job Blender.ie) as im currently looking for a job in ireland. Well, you seem so keen to blend jobs, i dont wanna steal your thunder
-
10:30 am on August 23rd, 2005Derek is still Derek.. he needs us to help him choose between his Spiderman and Darth Vader costumes
Leave a comment
No trackbacks yet.

3:50 pm on August 22nd, 2008
Don’t worry, my JavaScript sucks too
The standardization you speak of will never happen.