Archive for the 'AS2' Category

Flash loading and browser cache test-suite

Thursday, July 10th, 2008 by Thomas

As a little homage to our most popular and seemingly helpful blog post about the Nasty XML load bug in Internet Explorer I created an app that tests the caching behavior of the browser it’s running in.

To recap - Loading XML files in Flash over an SSL Connection in Internet Explorer fails if the “Pragma: no-cache” or “Cache-Control: no-cache” HTTP headers are set in the server’s response.
In AS2 the loading failed silently, in AS3 we at least get an IO Error #2032, which has been discussed several times (see below)

If you want to keep the browser from caching your dynamic content you’ll have to use other means.
Judging from my tests, the best headers to prevent caching without causing errors in IE are: “Cache-Control: no-store” and/or “Expires: Thu, 01 Jan 1970 01:00:00 GMT”.

You can access the test suite here:

Set the headers that you’d like the server-script to return and find out what happens when the same request is sent twice after each other.
Use the Live HTTP Headers Plugin for Firefox if you’d like to see what the server actually returns.

Other interesting insights

  • The problem still exists in Internet Explorer 7! Don’t know about Vista…
  • Here it’s suggested that “Cache-Control: must-revalidate” and “Cache-Control: max-age=0″ also work. While that’s true in the sense that they don’t cause an error IE, they don’t seem to prevent caching 100% - there is a timeout.
  • “Pragma: no-cache” causes the error in IE, but doesn’t actually prevent it from caching at all when it’s set on a non-ssh connection.
  • Firefox internally sets the expiry date of script files to the past - so unless you set the “Expires” header to the future it’ll never cache the content.
  • Safari and Firefox change their caching behavior when the “Last Modified” header is set. If it’s in the past they seem to be happy to cache the file for you.

PHP sessions

Note that in PHP, as soon as you use sessions with session_start() the no-cache headers are added automatically. You’ll have to replace those headers or turn the default behavior off in php.ini. To replace the headers (found in the comments of the original post, see also the session-cache-limiter function and comments):

session_cache_limiter(’public’);
session_start();
header (”Cache-Control: cache, must-revalidate”);
// or if you still want to prevent caching
header (”Cache-Control: no-store”);
header (”Pragma: public”);

Related links:

Job in Berlin - Flash Developer

Monday, December 17th, 2007 by Thomas

Update: This position has been filled. You are still invited to send us your CV, but please use the email address specified, and not the comments section.

We are looking for a versatile Flash developer for full-time employment in our Berlin office with a solid background in object oriented web development and experience in AS3. We are seeking a motivated and confident problem solver with an eye for interaction design and a passion for web technologies.

You will be working in an international team of experienced developers in Berlin, London and Tokyo. Your role involves working closely with our front-end designers and the developer team to implement projects ranging from mini-sites and virals to large scale consumer & corporate websites. You will be working on projects such as:

Requirements

  • 2+ years experience in Flash development
  • Solid AS2 and AS3 Skills (OOP)
  • Experience with Flash integration technologies (Dynamic content, XML, Webservices)
  • Bandwidth and performance-friendly coding
  • A feel for good interaction design and usability.
  • Experience in related technologies and APIs is an advantage (i.e. Papervision 3D, Facebook API, Java, PHP)
  • English speakers are welcome

Less Rain is a digital design agency based in London, Berlin and Tokyo. We work independently & across 3 offices, in a multicultural team. Our services are aimed at producing sophisticated, concept driven, tailor made solutions for online communication, ranging from corporate to consumer websites, interactive content creation and online games, from the local to the international. Our client list includes Red Bull, BBC, Getty Images, Stockland Martel, Nike, Mitsubishi, Sega, Panasonic, Volkswagen.

Salary is negotiable dependant on experience.

We’re looking forward to your informative application via e-mail, including a CV and links to recent projects you developed. Please send your application to Thomas Meyer, bewerbung@lessrain.com

For further information about Less Rain visit:

http://www.lessrain.com

http://blog.lessrain.com

Flash: FIVe3D

Friday, October 12th, 2007 by Luis

The FIVe3D initiative is an open source code for the conception of interactive vector-based 3D animations developed by Mathieu Badimon.

The classes are written in ActionScript 2.0 and based on the ActionScript 3.0 structure. The FIVe3D system imitates a classicActionScript 2.0 MovieClip organization and provides extra 3D functionnalities.

Worth to take a look.

Related Links:

Flash full-screen mode and Flash Player Update 3 Beta 1 (build 9.0.60.120)

Monday, July 16th, 2007 by Luis

It seems to be a small problem when triggering the full-screen mode in AS2 with the Flash Player Update 3 Beta 1 (build 9.0.60.120).

When triggering the full-screen mode from a button by using onPress handler under the Flash Player Update 3 Beta 1 plugin, the swf gets stack showing the hand cursor and blocking any kind of interactivity, instead the same trigger mode under the latest stable Flash Player version (9,0,47,0) behaves correctly.

The behavior is normal when triggering the full-screen mode from a button by using onRelease handler rather than onPress handler.

Since the Flash Player Update 3 Beta 1 is not release yet, this behavior can’t be considered as a bug (or maybe Adobe has changed the way you can trigger the full-screen mode) but just keep it in mind if you play around with this Flash player version and suddenly nothing works as you expected.

You can download the Flash Player Update 3 Beta 1 (build 9.0.60.120) here.

Test it here.