Posts made by Matt Bury

Picture of Particularly helpful Moodlers Picture of Plugin developers

Hi Josep,

I couldn't agree more. I think Flash has become such an important platform for eLearning - Adobe are pushing in the direction of eLearning more and more these days - that anyone in software development for educational purposes can't afford to ignore it. In my view, it should be regarded in the same light as PHP, XML, MySQL and HTML.

Moodle provides an invaluable framework for developing and deploying eLearning interactions and the existing standard modules provide a lot of functions for giving tests, collecting assignments and collaborative activities. Without Flash, however, Moodle is limited in the learning interactions that it can offer - you can reproduce some of what Flash can do with PHP and JavaScript, but it's so difficult that it restricts what you can do because of the time it takes to develop them. They're also quite limited and often end up being more like tests than lessons.

I work with techniques and theory for cognitive learning a lot for which Flash is ideally suited. Computer Assisted Language Learning can offer some very fast and effective learning activities for languages that I simply haven't seen on any other platform. The major closed source developers have all made a strong commitment to Flash. It would be foolish for anyone who is serious about eLearning not to.

Just my two cents worth.

Matt

Picture of Particularly helpful Moodlers Picture of Plugin developers

Thanks for the link Cathy, it'll certainly come in handy!

Having looked at the source files for the AS 2.0 Flash module, I have a bit of a problem. I can't find some of the classes that handle sending the data to serice.php.

There's stuff there to convert the values into an XML string but the actual moodleService function proves to be elusive. I'll have another look but if anyone can point me in the right direction, I'd be grateful.

The XML handling part will be much easier in AS 3.0 - Since it's a native datatype, there's no need to writed these long, convoluted functions to tack bunches of strings together before sending them to PHP. You just create an XML object and feed the data into it, in a similar way to an array. The XML class takes care of the rest for you. How easy is that?

Picture of Particularly helpful Moodlers Picture of Plugin developers

Yes, that's the idea.

The moodleService.* functions are in a separate object that handles the score, answers, and elapsed time variables from Flash and sends them to service.php. What I have to do is work out what format moodleService sends the data in, and try to reproduce that in AS 3.0. Since PHP and server side programming are not my forte, it's gonna be a quite an involved learning experience.

The reference books on Flash and PHP that I have are in AS 2.0. The way AS 3.0 handles external data is very different. The reference books I have on AS 3.0 only cover integrating Flash with PHP and server side programming very briefly. Any help from anyone would be greatly appreciated.

BTW - The AS 3.0 classes for this are: URLRequest, URLLoader and FlashVars.

Wish me luck!

Picture of Particularly helpful Moodlers Picture of Plugin developers
Here's a quick update on my progress:

I've decided, for the moment to try to bypass the Moodle Flash module and use the service.php and library.php scripts to communicate with the database directly.

I reckon a simple function within a Flash SWF that communicates with service.php should be enough, and not too difficult to implement for anyone who's authoring stuff in AS 3.0. It'd be a simple case of copying and pasting a few lines of code...

...or so I hope. I'll post details of my progress in the near future.

By the way, I was experiencing some strange behaviour in IE7 (don't we all!) from using the simple tags to embed my SWFs. I worked out a pretty good solution, which you can find on this post: http://moodle.org/mod/forum/discuss.php?d=88524

Wish me luck with my experiments!

Moodle in English -> General help -> Weatherbug Widgets -> Re: Weatherbug Widgets

by Matt Bury -
Picture of Particularly helpful Moodlers Picture of Plugin developers

Hi Charles,

Glad you've worked it out. Something I've noticed is that Moodle URL encodes the code I put into the HTML editor. I've had problems with getting embedded objects to work in IE7 in the past and  I find that if I copy and paste the tags that are already URL encoded, it works fine every time.

Hope this helps.

Matt