html - Extract the contents of a div using Flash AS3 -


i have sfw embedded in php page. there div on page id="target".

i want access content of div (ie: characters inside it) , hold them string variable in as3. how can this?

my attempt far

import flash.external.externalinterface; var mydivcontent = externalinterface.call("function(){ return document.getelementbyid('target');}"); var mydivcontent2:string = mydivcontent.tostring(); test_vars.text = mydivcontent2; //dynamic text output 

you're there :

var res : string = externalinterface.call("function(){return document.getelementbyid('target').outerhtml}"); 

if want content of target, use innerhtml instead of outerhtml.


Comments

Popular posts from this blog

linux - Using a Cron Job to check if my mod_wsgi / apache server is running and restart -

actionscript 3 - TweenLite does not work with object -

jQuery Ajax Render Fragments OR Whole Page -