Adding a dropshadow effect to a Display Object in Actionscript 3 is really easy. In Actionscript 3, Display Objects such as MovieClips have a property called filters.
To apply a drop shadow to your MovieClip, you must first import the DropShadowFilter. Then create a DropShadowFilter instance. Lastly, assign your new filter to the MovieClip’s filters property:
var dropshadow:DropShadowFilter = new DropShadowFilter(15,45,10,0.5, 10.0, 10.0,1.0);
myDisplayObject.filters = [dropshadow];
I won’t get into the values passed to the DropShadowFilter constructor to make this short and sweet. If you would like to learn more about the particulars of this filter, see: Actionscript 3 Reference Manual
This is a little off the subject of Actionscript 3, but I think it’s an important little trick to know for anyone building content for the web. So here I am going to show a quick php snippet that will find hidden malicious code in your website, or more specifically, how to find hidden ‘strings’ of code in your site.
I’m not going to get into the obvious stuff about how to protect your site, site as good ftp passwords etc, that is for another article. This is just to help you find the offending garbage once it’s already there.
1. create a new file, and call it finder.php
2. edit it, and paste the following code:
<?php $input="grep -r "."'"."keyword"."'"." *"; echo"Below is a list of all files containing your keyword:"; $output=shell_exec($input); echo"<pre>#$output</pre>"; ?>
3. change the word keyword to the malware domain name that google reported your site to be infected with.
4. save this file into the root folder of your website.
5. navigate to www.yoursite.com/finder.php
It will look through your entire site and return any instances of
I just wanted to leave a little note to let everyone know that this site is optimized for browsers that are NOT Internet Explorer. If you are using IE and notice weird things happening on my blog, well, they will not be fixed.
I spend a GREAT deal of my working days hacking css on other sites that I work on for my day job in order to make them compatible with IE. I refuse to do this with my own site. If (however) you find problems with funky things happening in standards compliant browsers such as Firefox, Chrome or Safari, then I will be happy to look in to it.
Thanks, and most importantly – IE Sucks. Install a modern browser (Internet Explorer 9 does NOT count)!