About Widgets Tutorials Forums
Space Shift
Tutorials

Step 1: Files and Folders:

When you un-zip the tools, you will notice that there are the following files:

'actionScript.as', 'index.fla', 'index.swf', 'index.html', 'userGuide', 'functionsList', 'Creative Commons Deed.htm'.

And the following folders:

'crossdomain', 'php', 'com'.

If you have all these folders, files and a working Internet connection then move onto the next step.If you do not have all the files, then please re-download them.

Step 2: Seting up files:

Open up the file 'actionScript.as'. You will notice that there are the following variables:

'var userWebPage:String = "http://www.myspace.com/jimboejw";'

'var loadHTML:String = "http://www.happyjimbo.com/spaceshift/loadHTML.php";'

If you go to the 'index.fla' file and go to Control - Test Movie (CTRL/Apple + Enter) the file will run. If you look at the Output window then you will see that the code will get the information from the Myspace page declared in 'userWebPage' (which is currently my Myspace page).

Now it is in your interests as well as mine if you have a web server available. If you do then you will need to make sure it runs PHP (just about ever server does these days) and then you just need to upload the files in the 'php' folder ('loadHTML.php', 'myspaceReplace.php') to somewhere on your server and then you need to change the URL address in the variable 'loadHTML', so it will looking something like this:

'var loadHTML:String = "http://www.yourwebsite.com/loadHTML.php";'

Unfortunately you need this file in place due to the Flash player security sandbox that will not let you access other webpages directly through Flash, so we need the PHP to get around this issue.

In the 'crossdomain' folder there is the file 'crossdomain'. Open this up in a text editor (something like notepad) and just change the two URL's inside this file to be that of the website where the PHP files are and upload it to the same folder as the PHP. Not all browsers needed this, but when I tried to view the work in the web browser Safari (Mac), it did not work until the crossdomain was uploaded.

Test the movie again, if this all works, then please move onto either the ActionScript 1 tutorial or the ActionScript 2 tutorial, depending on your preference.

Edward J Woodward : Valid XHTML 1.1 : Valid CSS