Flash Help
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me

The Shed is going Social! Join us on FaceBook and Twitter and chime in on the conversation.

Go Back   Dev Shed ForumsWeb DesignFlash Help

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old February 21st, 2013, 03:28 PM
tlmarker tlmarker is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jan 2013
Posts: 2 tlmarker User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 52 m 5 sec
Reputation Power: 0
ActionScript 3 - Weird navigateToURL behaviour

I have a custom class that post result from a Flash file to my website the in turns posts the data to a database. I create the string to post data to the website, I then use php to do the actual posting of the data. The problem I am having is the URL I pass to navigateToUrl does not take me to correct URL. The page displayed is the same page the Flash file is displayed on. However when I test to Flash program from the Flash IDE is goes to the right URL. I have a trace statement right before the navigateToUrl command, and It shows me the correct address but the address in the address bar of the browser is completely different.

The code for creating the url is below:
Code:
		public function submitScore(sid:int, rid:int, lid:int, cscore:int, pScore:int):void {
			var postScore:URLRequest;
			var postAddress:String
			var postData:String = sid + "/" + rid + "/" + lid + "/" + cscore;
			if (pScore == 0) {			
				postAddress = configFile[WEBSITE] + configFile[SUBMIT] + postData;
			} else {
				postAddress = configFile[WEBSITE] + configFile[UPDATE] + postData;
			}
			trace("Post Address: " + postAddress);
			postScore = new URLRequest(postAddress);
			navigateToURL(postScore);
		}


The value for configFile[WEBSITE] and configFile[UPDATE] are read form a config file and have the values of hrrp://mrsmarker.com and scores/update respectfully.
The value of postScore is http://mrsmarker.com/scores/update/1/4/1/20 (the numbers vary, and are not important at this time.)
The URL in the address line of the browser is: http://mrsmarker.com/students/viewTest/1/%3C!DOCTYPE%20HTML%3E/%3Chead%3E/1/4/1/20.
It appears the some html is injected into the postScore value, but I am not sure where it is coming from. Thanks for help, Troy.

Reply With Quote
Reply

Viewing: Dev Shed ForumsWeb DesignFlash Help > ActionScript 3 - Weird navigateToURL behaviour

Developer Shed Advertisers and Affiliates



Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 


Powered by: vBulletin Version 3.0.5
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.

© 2003-2013 by Developer Shed. All rights reserved. DS Cluster - Follow our Sitemap