Adobe Edge demo - first impressions...

Had a play with Edge over lunch - just a simple keyframe animation (which is all it can really do). First impressions:

  • fairly easy to use if not a little cumbersome – adding keyframes/tweens is a little on the convoluted side
  • no ability to add interaction
  • no scripting ability
  • as you'd expect it outputs a lot of files (.js, .css, .html, image files) - in the very simple animation I did the weight of these files was about 250kb. That's about 240kb more than doing the same in Flash. Flash would only be one file (maybe two if you use swfobject.js to embed).

Final verdict – good but I hope for a lot more features in the final release of the software. However – I still can't see how HTML5 will ever take over from Flash for high quality, interactive, rich media delivered via a browser.

Scaling embedded YouTube videos...

I posted my first blog entry with embedded video this morning. As you’d expect I simply copied the supplied embed code from the relative video on YouTube (with customised colour of course) and pasted it in my post*. As my blog text column is only 350pixels wide and YouTube’s default video width is 425pixels this meant that I had to resize the video whilst maintaining the videos width to height ratio. How? Easy...

In your YouTube embed code you will see TWO instances of:

width="425" height="344"

Simply change the BOTH the instances to the width and height you require. In my case the width="350". As the ratio of the YouTube window seems to be roughly 1.2:1 to find the height simply divide your width by 1.2

width / 1.2 = height
350 / 1.2 = 291.666 (I rounded down to 291)

Once you’ve plugged in your new numbers the video window will be nicely resized.


* Therein lay some problems leading me to have to download WLW Beta – but more on this later.

Modulus in Flash ActionScript 2...

The Modulus is the remainder of division between two integers. I was looking for this operator in Flash a little earlier. Flash CS3's help files are fairly difficult to wade through at the best of times and simply typing 'Modulus' into the search box didn't bring up any search results in Flash's help files.

I hit Google and discovered that the operator required is the % symbol:

X % Y = the remainder of X / Y

For example: 

10 % 3 = 1
10/3 = (3*3) + 1(remainder)

Silverlight? Leave Flash to the Experts...

I try to avoid being negative on my blog but I realise that its been sliding that why over the last few articles. I promise I be more positive in the future...

I have been noticing more and more pro-Microsoft sites (the ones that bang on about the latest laptops and Internet Explorer patches in the same way Apple-worshippers go on about Safari updates and the MacBook Air as if it was a gift from God) have started asking me to install 'Sliverlight'... Absolutely not! There is no chance I am going anywhere near this rival to Flash. Why do Microsoft have to keep inviting themselves to other people party's? They must have taken one look at the latest Flash Player statistics, saw the figure: '99% Penetration' and just couldn't resist a piece of that action. They have done this before.

Look at Internet Explorer. Back in the 'good old days' most users I knew used to install Netscape Navigator rather than use Microsoft’s IE. It was by far the superior browser, came with all sorts of other groovy web apps such as an email client, and was free (unlike Outlook). Microsoft soon cottoned on to the fact that if they could control the browser they could essentially control the internet. The used all sorts of dirty tactics to gain superiority over their better rivals and even had legal action taken against them so users could still be given the illusion of browser choice. Now, what PC users are left with is an operating system with the web browser integrated into almost everything. This is one of the reasons Windows has so many security risks. Most users now can’t be bothered to install anything else and you even come across websites where developers haven’t bothered testing on anything other than IE. And even this wouldn't be a problem if Microsoft hadn'yt seen fit to bastardise CSS. Somethig there were only able to do after they'd won the War of the Browsers.

I'm hoping that people shy away from Silverlight and don’t give Microsoft the chance to get a foothold on interactive and streaming content (because we all know that’s what they are after.) Yes, Silverlight seems to have a good technical spec but Adobe Flash is extremely good, has been number one for years and is the web standard. We don’t need yet another pluggin to install on our browsers.

Another reason to stick with Flash is because of the existing knowledge-base. The design industry has been using Flash for years and Flash content is of a very high quality. It seems to me that currently the only people authoring in Flash are Microsoft-sycophantic techies. Whilst these people are no doubt highly skilled at coding they don’t seem to have the design flair that makes Flash content of such a high standard.

So Microsoft - if it ain't broke, don't fix it! (Your time would be better spent fixing all your products that ARE broke!)

MSDC Flash site goes live...

After an enjoyable few weeks of Flash coding the MSDC Flash website I have been working on has gone live.

MSDC Flash Website

MSDC had a strong idea about the design of the site which left me free to concentrate on making it work nicely. I am pleased with the motion and little features such as the step by step loading of the images in the Work section and the zooming on the map in the Contact section.

Using an ampersand in ActionScript loadVariables function...

So I'm working on a project for Sky, its 1 hour to the deadline , and I think I better test the links which I am importing into the Flash project (for deployment on the Desktop as a Projector) from a txt file using the loadVariables function... This links look something like this:   (note the ampersands in there)

...and thats it! Everything is shot to hell because of the ampersands. When Flash imports using loadVariables it wants everything in a standard MIME format application/x-www-form-urlencoded (a standard format used by CGI scripts). This means variables are seperated by ampersands. For example:


So as soon as you stick an & midway through a URL in Flash thinks its come to the end of the variable and ignores the rest of the URL. Fine! I thought (at first)... I'll replace the URL with &... You see the irony there?

I furiously started hard coding the URLs and in doing so came across a way of replacing the & with its URL character code... Its so simple it hardly warrents writing all of this. Simply swap out all ampersands with %26. Its as easy as that! So:

Works a treat!

And in case you were wondering here's a list of other URL encoded characters:

URL Encoded Characters

backspace %08
tab %09
linefeed %0A
creturn %0D
space %20
! %21
" %22
# %23
$ %24
% %25
& %26
' %27
( %28
) %29
* %2A
+ %2B
, %2C
- %2D
. %2E
/ %2F
0 %30
1 %31
2 %32
3 %33
4 %34
5 %35
6 %36
7 %37
8 %38
9 %39
: %3A
; %3B
< %3C
= %3D
> %3E
? %3F
@ %40
A %41
B %42
C %43
D %44
E %45
F %46
G %47
H %48
I %49
J %4A
K %4B
L %4C
M %4D
N %4E
O %4F
P %50
Q %51
R %52
S %53
T %54
U %55
V %56
W %57
X %58
Y %59
Z %5A
[ %5B
\ %5C
] %5D
^ %5E
_ %5F
` %60
a %61
b %62
c %63
d %64
e %65
f %66
g %67
h %68
i %69
j %6A
k %6B
l %6C
m %6D
n %6E
o %6F
p %70
q %71
r %72
s %73
t %74
u %75
v %76
w %77
x %78
y %79
z %7A
{ %7B
| %7C
} %7D
~ %7E
¢ %A2
£ %A3
¥ %A5
| %A6
§ %A7
« %AB
¬ %AC
¯ %AD
º %B0
± %B1
ª %B2
, %B4
µ %B5
» %BB
¼ %BC
½ %BD
¿ %BF
À %C0
Á %C1
à %C3
Ä %C4
Å %C5
Æ %C6
Ç %C7
È %C8
É %C9
Ð %D0
Ñ %D1
Ò %D2
Ó %D3
Ô %D4
Õ %D5
Ö %D6
Ø %D8
Ù %D9
ß %DF
à %E0
á %E1
â %E2
ã %E3
ä %E4
å %E5
æ %E6
ç %E7
è %E8
é %E9
ê %EA
ë %EB
ì %EC
í %ED
î %EE
ï %EF
ð %F0
ñ %F1
ò %F2
ó %F3
ô %F4
õ %F5
ö %F6
÷ %F7
ø %F8
ù %F9
ú %FA
û %FB
ü %FC
ý %FD
þ %FE
ÿ %FF