Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 5980451
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 22, 20262026-05-22T21:48:09+00:00 2026-05-22T21:48:09+00:00

I am getting the following error: #1088: The markup in the document following the

  • 0

I am getting the following error:

#1088: The markup in the document following the root element must be well-formed

I am calling a php script from AS3 that grabs some XML data from a website and echos it to a page.

 myLoader.load(new URLRequest("http://www.mywebsite.com/my_test/my_Weather.php"));

to get around a cross domain issue.

The XML when viewing source in browser:

<?xml version="1.0" encoding="ISO-8859-1"?> 
<?xml-stylesheet href="latest_ob.xsl" type="text/xsl"?>
<current_observation version="1.0"
     xmlns:xsd="http://www.w3.org/2001/XMLSchema"
     xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
     xsi:noNamespaceSchemaLocation="http://www.weather.gov/view/current_observation.xsd">
    <credit>NOAA's National Weather Service</credit>
    <credit_URL>http://weather.gov/</credit_URL>
    <image>
        <url>http://weather.gov/images/xml_logo.gif</url>
        <title>NOAA's National Weather Service</title>

        <link>http://weather.gov</link>
    </image>
    <latitude>41.27</latitude>
    <longitude>-80.67</longitude>
    <observation_time>Last Updated on Jun 3 2011, 1:51 pm EDT</observation_time>
        <observation_time_rfc822>Fri, 03 Jun 2011 13:51:00 -0400</observation_time_rfc822>
    <weather>Mostly Cloudy</weather>
    <temperature_string>71.0 F (21.7 C)</temperature_string>
</current_observation>

I noticed it was using an XSL file to style the data in the browser. I think that is causing the issue:

My php my_Weather.php:

<?PHP

//ini_set("display_errors","2");
//ERROR_REPORTING(E_ALL);

header('Content-type: text/xml');

$xml_data = file_get_contents("http://www.weather.gov/xml/current_obs/KYNG.xml");

echo $xml_data

?>

And finally my action script:

var myXML:XML;
var myLoader:URLLoader = new URLLoader();

myLoader.load(new URLRequest("http://www.mywebsite.com/my_test/my_Weather.php"));
myLoader.addEventListener(Event.COMPLETE, processXML);

function processXML(e:Event):void {
    trace("load XML");
    myXML = new XML(e.target.data);
    trace(myXML);
    show_temp(myXML);
}

function show_temp(myXML):void
{
    temp_info.text = myXML.temp_f[0];
}

stop();

Pretty straight forward. But I am not sure why I am not getting the XML to import into Flash. Even if I strip out all the XSL data with php is still does not like the formatting.

please help.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-22T21:48:09+00:00Added an answer on May 22, 2026 at 9:48 pm

    Maybe, this won’t help you directly but I tested your code and everything works fine here: The XML content is traced in debug mode. I used the same AS3 code* and provided a PHP with exactly the same content on my web server.

    Therefore, I would guess that the problem has nothing to do with the shown sourcecode and lies in code which is not shown here or maybe web server configurations.

    —

    *Changes:

    • changed the URL to my own web server
    • made the functions private (using FlashDevelop with Flex SDK — maybe this is the sticking point)
    • myXML = new XML(e.target.data); -> var myXML:XML = new XML(e.target.data);
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am getting following error: error: calling a host function(strcpy) from a __device__/__global__ function(doDecompression)
I am getting following error with PHP 5.1.6: Fatal error: Declaration of Tl1Telnet::ExecuteCommand() must
Am getting following error message on calling WCF service: The formatter threw an exception
i am getting following error while getting data from dictionary -[__NSCFString objectForKey:]: unrecognized selector
I am getting following error while running index.php file on apache File does not
I am getting following error: COM object that has been separated from its underlying
i'm getting following error in my PHP file. Warning: include(../config/config.php) [function.include]: failed to open
When I am deleting a row from grid view I am getting following error.
immediately after has_many_polymorphs install with ruby script/plugin install git://github.com/fauna/has_many_polymorphs.git i start getting following error
I am getting following error while running local script/server of my Rails project: This

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.