View Full Version : [Q] Generate SWF with PHP from a form...
CyanBlue
04-14-2010, 05:05 PM
Hi... ;)
I remember doing a SWF creation with MING/PHP long time ago... But it wasn't really a pleasant experience if I recall...
Let's say I have a form that says 'Enter your paragraph:' and there is a text area down below and a Convert button next to it... The idea is that you enter your own text into the HTML text area and have it create a SWF with that text... If the text is larger than the height of the specified SWF, it'll need to throw in a scroller...
I did some googling and found one called Sphing...
http://sphing.sourceforge.net/
I also know that there is a commercial product called PHP Turbine, but that's not something I can afford cuz I am not making any dime with this...
http://www.blue-pacific.com/products/phpturbine/default.htm
Any thoughts??? ;)
Flash Gordon
04-16-2010, 08:28 AM
any chance of building mxml from the form and using the mxmlc on the server to compile the it into a swf?
CyanBlue
04-16-2010, 11:56 AM
Hm... That's an interesting idea... I feel like that requires a shell access to the server(probably a dedicated hosting) to execute the mxmlc, so that's not an option if that is the case...
Can you talk abit more on 'building mlml from the form' bit??? I kinda get it but not totally... It'd be nice one to know... ;)
Flash Gordon
04-16-2010, 05:58 PM
yes, you'll need shell access. dedicated or virtual private will give you that. Not sure about shared. probably not as it *could* (doesn't have to be) a security issue. You'd just invoke the compiler via command line. Note, not sure about the legalities of using mxmlc like that.
building mxml would be the same process as building xml, a form, or really any other state representation (e.i. database persistence) You're just representing a state. and then from there, you're just converting that state into a different format: swf. I would need to know more details about what you're doing to eleborate any further.
CyanBlue
04-16-2010, 06:03 PM
Yeah, that's what I am thinking as well...
I am almost tempted to dive into the Ming world again but that sure is painful one...
What I am trying to do... I am basically trying to create something that generates a SWF on the fly... Well, I am trying to create a SWF to replace the HTML text area so that it is harder to steal what's wrote in it to be exact...
On another community that I participate in is something that goes with amateur novel where somebody started to steal the content of it and post it somewhere else as if that's their own creation... and I am trying to make it harder to steal by moving the content into the SWF...
Since that community is a free site, it does not support anything like PHP, database or even JavaScript... So, I was thinking maybe I could spare some space on my server and have the authors use the tool to create the SWF, some automatic tool posts the SWF to another free online space and spit out the embed tag which the authors can use to post in the community...
So, anything external is not really an option since you can simply view source or sniff the traffic to steal the content...
Well, to recap, I want to create something that's standalone as is so that it is easy to embed and hard to steal... ;)
Flash Gordon
04-16-2010, 06:08 PM
for simple text, I'd go ming, as to reduce the server load and lag in creating the swf. If the specs were any more eleborate I'd look heavily into the mxmlc option. I've never done it like that (no need thus far), but I couldn't see why it wouldn't work.
You're kind of working with your hands tied....it's like trying to build a house when your only tool is a hammer.
CyanBlue
04-16-2010, 06:27 PM
Cool... Thanks for your help... ;)
Flash Gordon
04-16-2010, 06:35 PM
best of luck, my man.
CyanBlue
04-16-2010, 06:46 PM
Yeah, it'd be great if you can send me a couple more hammers... Thanks... ;)
Flash Gordon
04-16-2010, 10:13 PM
I would but I have have is nails right now..... :/ funny how things work that way sometimes.
CyanBlue
04-16-2010, 10:18 PM
Dang it... :p
Have a wonderful weekend... ;)
Flash Gordon
04-16-2010, 10:44 PM
cheers, my friend.
|
vBulletin® v3.8.5, Copyright ©2000-2012, Jelsoft Enterprises Ltd.