View Full Version : [Q] Can I track the usage???
CyanBlue
05-05-2004, 02:39 PM
Howdy... :)
I made a Flash game that is used in the ad... and some company that distributes the ad opens it up as pop under window... In the ad, you can play the game and you have an option to go to the site and so on... You get the idea on what it is... :)
My quesiton is... Is there any way I could keep track of how many times the game was played??? I personally don't really know and don't want to know how many times the ad actually enticed the user and let them visit the site... I just want to know how many times the game was actually played... Basically the user clicks on the Start button to start the game and Play Again button to play it again... So, clicking on those buttons should be the one that triggers the count... But the thing is that I cannot call any server side script because of the security stuff we all know... and I don't think I can add any JavaScript or whatever within the HTML file that is containing the Flash game...
Any idea??? :)
Thanks...
McGiver
05-05-2004, 04:08 PM
I have no Idea what security stuff you mean, but as far as I know, server scripts are the only thing that will work here.
I wrote some kind of stats script for my footer in php too, and it works quite fine:
http://www.digitalhalo.de/footer/statsv6/stats.php
(since I made the script for me only, it is possible that you can't see the stats (for example when using an other browser than IE))
CyanBlue
05-05-2004, 04:47 PM
Um... Okay... I am totally lost here... :(
You have your banner game hosted within the AS.org's HTML file(PHP file actually), and you can call PHP file in your domain by using LoadVar() object and there is no security restriction at all??? I mean the cross domain restriction... Or was that cross domain restriction only applies when I want to load something from the PHP file??? I am confused... :(
use allowDomain("domain name"), and just do a send to a php file. then just use php to increment your counter.
McGiver
05-05-2004, 06:25 PM
I did it with LoadVars, and since there were no problems concerning that I didn't think a lot about that. And to be honest, I never heard of cross domain sending or loading restrictions for variables :confused:
here's a cross-domain policy explanation by moock
http://www.moock.org/asdg/technotes/crossDomainPolicyFiles/
jon
CyanBlue
05-06-2004, 09:09 AM
Thanks, uten, but I am not really talking about that 'new' restriction...
Maybe I have something strange stuck in my brain... :(
What about this???
I am testing my Flash movie within the Flash authoring environment which has this line...
some_lv.sendAndLoad("http://www.whereva.com/someScript.php", some_lv, "POST");
and it's got to work because the SWF is considered as projector which has no cross domain restriction...
But if I upload that SWF file into http://www.mydomain.com and use http://www.mydomain.com/index.html to open it up, that some_lv.sendAndLoad() call won't get fired because of that restriction...
Am I right on this or not???
farafiro
05-06-2004, 09:53 AM
have u read the security chapter in the documentations of flash??
Ithink it'd help very much
i still think allowdomain should work for you.
CyanBlue
05-06-2004, 10:27 AM
Oh... Don't get me wrong, tg... I think that will work too... :)
I am just curious whether cross domain security stuff that I was thinking is correct or not... Know what I mean???
For example, the example that I have said my last post, projector vs SWF on the web, is pretty much the fact if I remember correctly... But if that security restriction can be easily broken by using allowDomain, why do we even need the security restriction??? Get my drift???
I've used LoadVars() from http://www.domain1.com which called an ASP script on http://www.domain2.com/folder/file.asp before and I never had any problems with it. I was under the impression the security concerns were on the server hosting the backend stuff. Its a web server, technically everything is cross domain.
@cb, ooohhhh. so we have a different approach here, you actually want to know the theory, and to learn something, where i just want to get the stinkin thing to work, and move on.
CyanBlue
05-06-2004, 01:15 PM
Hehe... Not really, tg... I wasn't sure if I was remembering something correct or not... I am doubting my memory thesedays very much often... :(
As for the testing... Yeah... I sure can try that myself with PHP, but it doesn't work that way in this place... I'd need to request the upstair guy to create an ASPX page that stores data just to test... and I don't want to do that myself when somebody else can do that for me... :D
(Um... I might if I feel really lazy at home...)
|
vBulletin® v3.8.4, Copyright ©2000-2009, Jelsoft Enterprises Ltd.