Skip to Content

jQuery

Important notes about javascript.

Using || in a namespace declaration.

var MyNamespace = MyNamespace || {};

This will establish a new empty object only if MyNamespace does not pre-exist. Very cool.

$(document).ready(MyNamespace.init);//drop this into .js file to get things rolling. Now I'm going to try some of this, only not in this page.

calling drupal functions

Background:

Once upon a time, connecting Flash content with a database backend involved writing php pages and calling them from Flash. Over the years, the method for calling them evolved somewhat, but prior to AS3, things stabilized around the excellent LoadVars object. Within your php page, you would connect to the database, run queries, and return the results to Flash formatted as a GET string.

Flash for Drupal

This blog will chronicle my attempts to integrate Flash content into Drupal. Although word has it that support for Flash is best achieved via the Services module, my efforts are focused on what can be accomplished securely without Services and without AS3/Flex.

Syndicate content