While working on a project for work today, I encountered a problem that I apparently have never encountered before. What I thought was a very simple function call in jQuery turned out to be a bit more complicated. I needed to removed an HTML element from a string representation of an HTML snippet. jQuery doesn’t quite behave the way I expected and I had trouble finding a solution.
Continue readingSkyBlue CMS is now on GitHub
All things must eventually come to an end. SkyBlueCanvas lightweight CMS is officially at the end of its life. I built the very first incarnation of the software in 2003. Over the course of 8 years I spent thousands of hours developing the software and providing support. All of this was done for free. The software was downloaded over 50,000 times. I had an opportunity to interact with many very nice people around the world and made a few good friends in the process. But it is time to move on to other things. Continue reading
jQuery Plugin to Toggle Default Field Value on Focus and Blur
I can’t begin to count the number of times I have coded the same search field with the default value “Search…” in it and so that when the field receives focus, the text is cleared but magically reappears when the field blurs. Every time I code it I know I should save that snippet of code somewhere but it is always faster to just write it anew each time. Well, no more. I finally got around to writing jQuery plugin to allow me to add the focus/blur default value toggle to any field. I have very creatively named the plugin ‘Defaultify’.
Continue readingTheming Custom Entities in Drupal 7
One of the most useful features of Drupal is the ability to define one’s own content types and field types. Prior to Drupal 7 one could create custom content types (limited to Title and Body fields) without using any third-party modules, or add custom fields to existing content types using the Content Construction Kit (CCK) module. In Drupal 7 most of the features of the CCK were moved to the Drupal Core so it is even easier to create custom content types and add an arbitrary number and arrangement of predefined as well as custom fields to an entity.
Drupal 7 also saw the introduction of a new concept in custom content types: entities. Through this new API, Drupal 7 allows you to define a completely custom type of data object or entity which can have its own menu paths, callback handlers, and access, display and storage rules. Continue reading
Should I Use a CSS Framework?
I recently had a conversation with a colleague about whether or not it would be beneficial to use a CSS framework on some of the enterprise web sites we build. His response was that he had experimented with them but he isn’t a fan of them. His reasons are consistent with the arguments I have read posted on various places on the world wide web. I, on the other hand, am not convinced by the arguments against using them. Continue reading
CSS Framework Comparison
Simple jQuery Plugin Example
Trigger Custom Events with jQuery
Things have come a long way since the early days of the web and standard JavaScript window.onload and element.onclick event handling. Even using JavaScript on your web page was risky business in the early days because the availability and acceptance of JavaScript was so unpredictable.
Continue readingPluggable jQuery Application
A couple of years ago, while integrating the WYMeditor Semantic HTML editor into SkyBlueCanvas lightweight CMS, I experimented with different ways to simplify adding custom buttons and fuctionality to WYMeditor.
Continue readingNamespaced Events with jQuery
A few days ago in a post titled Trigger Custom Events in jQuery, I demonstrated how to work with jQuery.bind() and jQuery.trigger() to create and execute custom events. This article will explore jQuery events a bit more by taking a look at namespaced events.
Continue reading