Hi! Is there an as3 solution for extracting file content from uncompressed tar files around? / Jonas
I haven't seen an as3 tar library. There are zip libraries out there though, like nochump's zip and fzip. A workaround would be to tell the server to make the requested tar into a zip, load into flash, and once you have the content, tell the server to whipe that zip. It's a big long and has unnecesary steps if you had a tar library for as3. The other option would be obviously to make your own tar library.
I have used nochump's zip and had no problems, but since you need no compression this would make the whole thing complex for no reason. How about not using any compression at all, and not package the whole thing into a tar. Try Bulk Loader:. Seems to fit your needs. If you don't feel like manually adding all the files manually you could probably generate an xml on the server, something generic like:
<files>
<file url="/images/icon.png" id="icon" />
...
</files>
Load that with an URLLoader, loop through the nodes, add the items to bulk loader and start the whole loading process.
try hxformat, a haXe-library supporting a multitude of formats, including tar
... you will need haXe for that, either using swc output or ActionScript 3 generation ...
a little side note: personally, i'd recommend switching from as3 to haXe anyway ... haXe can also be translated to PHP, which you are using as well, so you could conveniently use it on both client and server ...
edit: yes, actually haXe can be compiled to swfs directly, resulting in faster bytecode than as3, but you can always use as3gen, if you want to ... haXe/php is also very cool, because it produces php code, but you can use haXe, which implies, that it's strictly typed and that the whole API is exposed in a consistent and nice OO way ... haXe does not even allow top level functions ... but if your really need it to do some dirty stuff, you can use inline php of course ...
the API also contains many helpful things, as the SPOD layer (package php.db) for clean and simple database access ... the tutorial is for neko, but that does not matter, because actually the haXe/PHP and haXe/neko standard APIs are fully compatible ... this also implies, that porting from php to neko (which significantly faster and more effictient in some cases) usually is a matter of remaping package php
to package neko
using a compiler directive ... haXe is THE solution for using the deploy-anywhere advantages of PHP, whilst using a really great language ...
also haXe is much more expressive than both AS3 and PHP ... it has enums with parameters, generics, structural subtyping, etc. ... there are some drawbacks, due to the fact that it is platform independant, but these will only occur if your code is not strictly typed ... sounds like a lot of typing, but the compiler infers many types, so by initializing a variable, it is already strictly typed ... :)
oh, and if you really want to use haXe, have a look at haxelib, which has many cool libraries ...