Stephen's dev blog

Archive for August 2008

jQuery create a client-side MVC

Posted by: Stephen Gray on: 28 August, 2008

jquery, mvc, framework

XML namespaces

Posted by: Stephen Gray on: 26 August, 2008

If you’re a developer, I’m sure you would have seen XML namespaces somewhere before whilst looking at an XML document. But what are they? According to the Wiki page:
“XML namespaces are used for providing uniquely named elements and attributes in an XML instance. They are defined by a W3C recommendation called Namespaces in XML. An [...]

jQuery create a simple plugin

Posted by: Stephen Gray on: 11 August, 2008

This is just a quick tutorial (more of a code snippet) for creating a very simple plugin for jQuery.
Of course, there are lots of tutorials around for this, this is mainly for reference
$.fn.myFunction = function()
{
    // use the following loop to iterate through all objects
    // returned by the jQuery selector which was used
    return [...]

Tags: ,

Flex getting selected RadioButton value

Posted by: Stephen Gray on: 11 August, 2008

This is a pretty simple one but there are surprisingly few tutorials showing the user simply how to get a selected RadioButtonGroup’s value.
There are quite a number of tutorials covering change event triggers for RadioButton controls but this is slightly different.
Say you have a form and you want to process the RadioButton value after submitting [...]

Flex Processing XML response from HTTPService

Posted by: Stephen Gray on: 8 August, 2008

There are a number of tutorials on doing this around the web but I thought I’d write my own tailored tutorial on this topic.
I’m going to cover two scenarios;
Assigning XML results as a dataProvider:
This is by far the simplest of the two:
// The initialisation function
protected function init():void
{
    var serviceObj:HTTPService = new HTTPService();
    serviceObj.resultFormat = ‘e4x’;
    serviceObj.method = ‘GET’;
    serviceObj.useProxy [...]