Update 2010-04-04: I’ve reviewed version 1.2 (see “ActionScript 2: Bugfixes in ‘ActionScript 2.0 Arabic Parsing v1.2′”). Update 2010-03-26: The author has just released version 1.2 of the “ActionScript 2.0 Arabic Parsing” that includes my bug fixes and other improvements. You can find the new version here. ActionScript 2 and the Flash Player up to version [...]
Read more…Archive for the ‘Programming’ Category
ActionScript 2: Cast object to array
Explicit conversion (casting) in ActionScript2 is very easy. Just put the variable in parentheses and precede the (new) type you want to cast to, like: var i:Number = 1; var b:Boolean = Boolean(i); trace(b); // outputs "true" Trying to cast an object to an array using this technique does not result in the expected output. [...]
Read more…Hibernate interceptors: Update entity’s properties “on update” and “on save”
An Hibernate interceptors provides a highly flexible way to hook into the session’s life-cycle to invoke your custom methods at particular session states, like before an entity is persisted and/or updated. Specially in multi-tier applications interceptors can be useful to plug in (entity) functionalities on a very clear way instead of scattering them through the [...]
Read more…SCORM 1.2: IMS Content package to examine the LMS API
To easily examine the Learning Management System’s Scorm 1.2 API I’ve extracted the “SCORM API Exerciser” from an “SCO Test Wrap for SCORM 1.2″ developed by Click2Learn and put it into an IMS content package zip file. You can upload/import that IMS content package zip file in any Scorm 1.2 compatible LMS. The SCO (Sharable [...]
Read more…CakePHP: Simple Google Analytics integration
The easiest way to integrate Google Analytics’ JavaScript tracking code in your cake application is to add Google’s code snippet in the file app/views/default.ctp. To be a little more flexible you can store the tracker code in the application’s configuration file (/app/config/core.php). Moreover you can define a CakePHP (view) element that can be reused in [...]
Read more…ActionScript 2: Create dynamic FLVPlaybacks with attachMovie
There is a simple way in ActionScript 2 to dynamically create instances of the FLVPlayback component: Put the FLVPlayback component into your library (you can drag’n’drop the component from the components window into the library). Use the following two lines of code to attach the FLVPlayback to a MovieClip (_root in the simple example) and [...]
Read more…