I am having a bit of trouble retrieving variables from an ASP page. It returns the entire page whereas I just need the variable strAnswer from the page. Any suggestions? Please help.
Here is my code:
var loader:URLLoader = new URLLoader(); loader.addEventListener(Event.COMPLETE, onDataSaved); loader.dataFormat = URLLoaderDataFormat.VARIABLES; var request:URLRequest = new URLRequest("http://" + host + urlPath + "setXML.asp"); request.method = URLRequestMethod.POST; var variables:URLVariables = new URLVariables(); variables.xmlString = str; variables.eltGuid = eltGuid; request.data = variables; loader.load(request); private function onDataSaved(e:Event):void { var loader2:URLLoader = URLLoader(e.target); loader2.dataFormat = URLLoaderDataFormat.VARIABLES; trace(loader2.data.strAnswer); }
With Page.Response .Clear() .CacheControl = "no-cache" .ContentType = "text/xml" 'use "text/html" if not XML .Expires = -1 .AddHeader("Pragma", "no-cache") .Write("<root><row></row></root>") .End() ' This should stop the rest of your html markup showing. Alternatively you could remove the markup from the page.End With
Squarespace’s all-in-one platform gives you everything you need to express yourself creatively online, whether it is with a domain, website, or online store. Get started with your free trial today, and when ready, take 10% off your first purchase with offer code 'EXPERTS'.
First things first - Preparation
We need all the part for this install and it's much nicer to have them all on hand when you need them so here's what's required.
Download Eclipse 3.5 32 bit (I like the Classic flavour) from here. (http://www.e…
In my long career of working as an actionscript developer, I had spent sleepless night often working hard to solve some small problems which actually took a lot of my development time; later found out the solutions to be a line or two.
Here are s…
In this tutorial viewers will learn how to create a basic motion tween animation in Flash
Open a new document in Flash: Draw/import an image: Press CTRL + F8 to convert it into a graphic symbol: Select a frame (how long you want the tween to last): …
In this tutorial viewers will learn how to create a basic shape tween animation in Flash including shape hints for smooth animation
Open a new document in Flash: Draw a shape: Select another frame (how long you want the tween to be): Right click and…