Posted by Jon on Jun 30, 2008 in Development, PHP | 0 comments
Over at Phly, boy, phly, Zend Framework coder Matthew Weier O’Phinney, talks about issues with implementation of namespacing in PHP 5.3 and the coding standards of Zend Framework.
The issue is, that the PHP parser does not allow class Abstract, neither interface Interface as both “abstract” and “interface” are reserved keywords. So Zend suggests prefixing interfaces with “I” and abstract classes with “A”. Hungarian notation for classes and interfaces.
It’s definitely a good read if you are looking into using namespacing in PHP 5.3 and what issues it may bring up with you code. Read it now »
read more
Posted by Jon on Jun 24, 2008 in Development, ExtJS, IMS, JavaScript, PHP | 0 comments
So part of my job at the Indianapolis Motor Speedway is writing Admin Tools for our users to administer the sites with. There are a mix of older admin tools which don’t use any JavaScript and newer admin tools where the front end is completely based on JavaScript.
I was recently asked to build an admin tool to allow one of our users to maintain the drop down portions of the site navigation since they can change with each passing event that happens at the track. This presented the following problems:
- Navigation is stored in a XML file
- The navigation XML file is versioned with Subversion
- The admin had to be easy to use.
What I started with was trying to figure out the whole svn integration thing as I had to figure out a way to make sure that the working copy was always current and that when the user saved the navigation it did a commit on the file to that way it would always be the latest version in the repository.
Problem 1: SVN does not allow you to checkout a single file to be a working copy. I found this to be a problem as I didn’t want the whole directory, I just wanted the navigation.xml file. I did some searching on the SVN bug tracker and found a perl script that David Kilzer wrote that allowed me to check out a single file. Problem 1 is solved.
Once I got the file checked out into the working directory on the server i preceded to write a shell script that updated the file via an svn up command that would be ran on my fetch script before I read in the XML file to pass it back to the JavaScript.
Now that I have the XML back in my front end i can display it. Here is what the admin tools looks like when you have selected which site you want to edit.

As you can see from the screen shot everything is layout in an easy to browse tree view. You can move the child nodes around to order then or place them in any parent menu that you like. There is a simple edit and add features. The adding also incorporates a feature from our Site Pages admin that allows you to select from a page in there so you don’t have to copy and paste a link from the pages admin to this admin.
Once the user gets done with any changed they may have they can select the save button and that passes it back off to the PHP backend where it writes out the xml file and then does an svn ci on the file which places it back in the SVN repository and also promotes it to production via a set of PHP and bash scripts to interface with the SVN repository.
All in all using the ExtJS Library and PHP to build the admin tools for the IMS sites has dramiticly cut down on the time it takes to do everything since I have a very good understand of how everything in ExtJS works and when I don’t there is a great documentation resource out there.
read more
Posted by Jon on Jun 18, 2008 in Development | 5 comments
O.K. so Firefox is an awesome browsers but it has a rather annoying feature that I’ve been trying to disable for some time now. When ever you click and hold on a link it put’s a dotted line around the link and then leaves it there after you have clicked on the link.
To me that is rather annoying to me as I do a lot of AJAX stuff and it requires me to get that link with in the DOM and tell it to blur it’s self (lose focus).
Just yesterday I stumbled across this code on the web while looking for something else:
* { outline: none; }
What this does it tell any object not to have an outline around it.
That works for me.
read more
Posted by Jon on Jun 16, 2008 in Development | 0 comments
IE8 should make things a lot better —but it will still fall far short of the standards set by Firefox, Safari, and Opera. Some of these problems are technical, but others are cultural. Where the other browser developers are open and communicative, Microsoft is still leaving web developers in the dark. Read the full article over at ars technica.
read more
Posted by Jon on Jun 15, 2008 in Development, JavaScript | 0 comments
Thanks to the guys over at tuaw.com for linking to this article.
———————————
Roughly Drafted has an interesting (and long) article that discusses Apple, Adobe, Google and Microsoft, and their different approaches to developing rich applications for the web. The article is very readable for a non-technical audience, and well-researched, too.
The article contrasts Apple’s mature development tools and platform frameworks with Google’s new open-source tools (like Google Gears). Further, it discusses closed frameworks like Adobe Flash and Microsoft Silverlight, and why Apple is ignoring those in favor of open-source, standards-based development for both apple.com and support for the iPhone.
Then it gets good. Daniel Eran Dilger writes about Charles Jolley’s SproutCore, a JavaScript framework that Apple has adopted for its own rich web apps, based on a Cocoa-like model-view-controller foundation with bindings, key value observing, and view controls. Think JavaScript on Rails. SproutCore bares its teeth at Adobe’s development tools, all ready to show off in Apple’s upcoming release of Mobile Me.
“That makes SproutCore a light Cocoa alternative for deploying web apps that look and feel like Mac OS X desktop apps,” Dilger writes.
read more