I'm having a strange problem that I'm trying to solve and I cant seem to figure out why this is happening. I have a Flex Application doing an HTTPSERVICE request to an external .ASP file on the website. This file has code the executes and sends data back to the application. All that work fine but in the ASP file I have some Javascript code (website tracking script) that dont run when called from within the Flex App. If I run the ASP page by itself (out side from flex), the scripts run. Is it not possible to have the JavaScript run in the ASP when called from a Flex Application? Any help would be greatly appreciated.
Thanks,
John Baranowski
Views
Replies
Total Likes
I think that's because the js is executed when the page is loaded in a
browser so probably you must try to tweak the js a little bit
Sincerely,
Michael
El 22/04/2009, a las 17:27, paranetrix5394 <forums@adobe.com> escribió:
>
I'm having a strange problem that I'm trying to solve and I cant
seem to figure out why this is happening. I have a Flex Application
doing an HTTPSERVICE request to an external .ASP file on the
website. This file has code the executes and sends data back to the
application. All that work fine but in the ASP file I have some
Javascript code (website tracking script) that dont run when called
from within the Flex App. If I run the ASP page by itself (out side
from flex), the scripts run. Is it not possible to have the
JavaScript run in the ASP when called from a Flex Application? Any
help would be greatly appreciated.
>
Thanks,
>
John Baranowski
>
Views
Replies
Total Likes
So your saying that the Javascript should run in the ASP page when called from a Flex Application using the HTTPSERVICE?
Views
Replies
Total Likes
I'll say yes.
Views
Replies
Total Likes
Here is what I think is going on but I can't prove it yet:
The scripts are javascript based which are executed in the clients browser after a typical web page is loaded into a browser. So if you were to run the ASP file alone in a browser, the asp code executes server side then outputs the html code (including the javascript code) then the server sends that code to the clients browser and displays the html code and then the browser runs the scripts.
In the case of Flex or any ajax/web2.0 application, the application calls the .ASP file to be executed and the server does its thing the same as before but the code that the .ASP sends back to the browser never gets loaded into the browser but instead gets intercepted by the requesting flex application.
Can someone vouch for my thinking? I don't want to waste time trying to make this work if it cant.
Views
Replies
Total Likes
I agree, the difference is that ASP is a dynamic page and it gets processed on the server, while JS is processed on the client, so when you request a page through Flex there's no client so that never gets trigger, I'll recommend you to add your own tracking, or if you find anything better please let me know.
Views
Replies
Total Likes