Tuesday, April 3rd, 2007
pack:tag: Compressing JSP Taglib
Category: JavaScript , Java , Library
pack:tag is a static-resource compressing JSP-Taglib. It caches ad hoc compressed JavaScript or CSS in memory (in a Java Servlet) or in a generated file. It works transparently to the developer and the compressing-algorithms are pluggable.
Features
- Minification of JavaScript and Cascading Style Sheets
- Caching to filesystem or memory (servlet)
- When caching to memory, the minified content is additional gzipped
- Apache Standard Taglib support for evaluations
- Compression and hashcode-generation adjustable on single resources
Examples
You would use JSP tags such as the following in your JSP files:
-
-
<pack :script src="myJavaScriptFile.js"/>
-
<pack :style src="myCascadingStyleSheet.css"/>
-
<pack :script src="myJavaScriptFile.js" enabled="false"/>
-
Posted by Dion Almaer at 8:26 am
Comment here
Cruiser Behaviors Library
Category: JavaScript , Library , CSS , Unobtrusive JS
Dan Yoder has created the Cruiser Behaviors Library, extensible stylesheets for decorating
DOM elements with interfaces and event handlers.
Cruiser uses Prototype, and is inspired by the Behaviour library itself.
A simple example shows the library in action. A new behaviour of "strike out a link with the special class of 'demo'" is added to the page by doing:
Creating a strikable class
-
-
Strikeable = Class.create();
-
Strikeable.prototype = {
-
strike : function() {
-
var html = this.innerHTML;
-
this.innerHTML =
-
html.tagify('del');
-
}
-
}
-
Creating an ESS file
An ESS file is extended CSS and this sample looks like:
-
-
a.demo { mixin: Strikeable; click: strike; }
-
Tie in the ESS
To link in this ESS file you need to use a link tag similar to CSS:
-
-
<link rel="extended-stylesheet" type="text/ess" href="/stylesheets/demo.ess"/>
-
Read more details on Cruiser.
Posted by Dion Almaer at 7:47 am
Comment here
Ajax CRUD with Struts 2 and TIBCO GI
Category: Java , Articles , TIBCO
Brian Walsh has written an article on Ajax CRUD with Struts 2 and TIBCO GI:
In this article you will learn how to create a new Ajax RIA front end to an existing Apache Struts2 .jsp application using TIBCO General Interface (GI), an open source Ajax toolkit with a MVC architecture similar to that of Java Swing. GI is optimized for creating business productivity applications and communicating with XML, SOAP, JSON and other types of services in a SOA.
Specifically we’ll extend the Struts2 CRUD (create, retrieve, update, delete) sample that comes with its installation to expose XML data services optimized for GI interoperation and create the Ajax application that connects the end user with those services though a rich graphical user interface. The intent behind this approach is to demonstrate how you can make incremental changes to existing applications rather than having to rewrite from scratch.
Posted by Dion Almaer at 6:17 am
Comment here
The Ajax Experience: Call for Presenters SF 2007
Category: The Ajax Experience
With great pleasure we announce two things: First, the Ajax Experience is coming to San Francisco once again! We had an absolute blast at the show last year and are looking forward to the second time around. We'll be holding the show from Wed. July 25 - to Fri. July 27 at the Grand Hyatt.
Second, our Call for Presenters is officially open. Please send proposals in by Monday, April 16. We know that's short notice, so we may look at proposals sent in as late as April 23 -- but those sent it by April 16 get the highest priority.
As with our Boston show's Call for Presenters, we are interested in the following topics:
- User Experience / User Interface design (high-level and HTML/CSS specific talks)
- JavaScript
- Frameworks: JavaScript (client and server-side -- here's looking at you, Phobos), .NET, PHP, Java, Ruby, Python, etc.
- Case Studies / Practical Advice from hand-on experience
Speakers get a free pass to the show and paid airfare and lodging.
Click here for more details on the Call for Presenters, including where to send abstracts, etc.
Looking forward to seeing you at the show!
Posted by Ben Galbraith at 12:00 am
3 Comments
Monday, April 2nd, 2007
Packer 3.0 and isMSIE hacks
Category: Utility , Tip
Dean Edwards has released Packer v3.0, one of the top utilities to squeeze your JavaScript like a lemon.
- respects Microsoft conditional comments
- new option to shrink variable and argument identifiers
- removed the special chars feature
(except the;;;
feature which people seem to like)- some bug fixes:
- packer no longer closes spaces between the
+/-
operators so code like this is safe:c = a++ +b;
- the
throw"error"}
bug that affected Safari (this is a Safari bug really but packer gets around it)- the
__proto__
bug for Mozilla browsers (this only affected the online version of packer)- a minor parsing bug affecting the detection of regular expressions
- simplified the user interface