<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Brady White &#187; compiled css</title>
	<atom:link href="http://www.bradywhite.net/tag/compiled-css/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.bradywhite.net</link>
	<description>Development and Life</description>
	<lastBuildDate>Thu, 24 Nov 2011 00:52:06 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
		<item>
		<title>Flex 3 &#8211; How to load a  complied css swf</title>
		<link>http://www.bradywhite.net/2008/05/05/flex-3-how-to-load-a-complied-css-swf/</link>
		<comments>http://www.bradywhite.net/2008/05/05/flex-3-how-to-load-a-complied-css-swf/#comments</comments>
		<pubDate>Mon, 05 May 2008 15:25:26 +0000</pubDate>
		<dc:creator>Brady White</dc:creator>
				<category><![CDATA[Flex]]></category>
		<category><![CDATA[Tips]]></category>
		<category><![CDATA[compiled css]]></category>
		<category><![CDATA[swf]]></category>

		<guid isPermaLink="false">http://bradywhite.net/?p=69</guid>
		<description><![CDATA[When attempting to load external compiled css swfs that have an embedded font into my flex application I was getting this error: Unable to load style(SWF is not a loadable module).  This is reported as an official bug on adobe's site at:  <a href="http://bugs.adobe.com/jira/browse/SDK-15393">Enable Local App to load RunTime CSS.swf from Server</a>

To solve this, you require two things.
<ol>
	<li>Crossdomain Policy</li>
	<li>Local Apache Web Server</li>
</ol>

Regardless if this is a bug, the host server still needs a crossdomain policy at the root of the domain.  Here's an <a href="http://curtismorley.com/2007/09/01/flash-flex-tutorial-how-to-create-a-crossdomainxml-file/">example crossdomain.xml policy</a>.

The next problem is that you cannot load external compiled swfs from a
document root (c:/my documents/flex projects/myProject/myProject.html) until the bug is fixed.

<strong>PC Users:</strong>
What I did is installed <a href="http://www.easyphp.org/index.php">easyphp</a>.  Next, I set up an alias in easyphp to my bin folder so that when I access the url http://127.0.0.1/myProject/myProject.html it loads up my bin
directory.  Also in my debug settings in flex I set the default debug and run path to launch as http://127.0.0.1/myProject/myProject.html.

Now my css/style swfs are loading great remotely.  The only downside is having to run easyphp on top of everything just to load in my external compiled font swfs.

<strong>Mac Users:</strong>
<i>Thanks to <a href="http://www.barrand.net">Bryce Barrand</a></i>
<ul>
<li> go to system preferences</li>
<li> click on sharing</li>
<li> click on "web sharing" (this will turn on the automatically installed version of apache)</li>
<li> edit apache's httpd.conf file (should be found at disk/private/etc/apache2/httpd.conf)</li>
<li> Find the line that says /Directory>
<li> Just after that, add an Alias for each project that you want to test such as this:

Alias /nameOfAlias /pathToYourFlexBinFolder</li>

<li>Set your directory node attribute to "/pathToYourFlexBinFolder".  Set the directory node value to:


   Options Indexes FollowSymLinks MultiViews<br />
    AllowOverride None<br />
    Order allow,deny<br />
    Allow from all<br /></li>

<li>Restart the webserver by unchecking and rechecking the "web sharing"  checkbox</li>
</li></ul>
should be good to go after this. you can see the results by going to http://localhost/nameOfAlias in your browser <br /> <a href="http://www.bradywhite.net/2008/05/05/flex-3-how-to-load-a-complied-css-swf/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
		<wfw:commentRss>http://www.bradywhite.net/2008/05/05/flex-3-how-to-load-a-complied-css-swf/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

