Loading ...
Sorry, an error occurred while loading the content.

Connection Manager

Expand Messages
  • Navaneeth
    Hi, I have started using the Yahoo Connection Manager for my applications and noticed that every once in a while a async connection fails on IE giving an error
    Message 1 of 14 , Aug 10, 2006
    • 0 Attachment
      Hi,

      I have started using the Yahoo Connection Manager for my applications
      and noticed that every once in a while a async connection fails on IE
      giving an error popup saying "500:Server Error". On the Server side,
      this translates into a "java.net.SocketTimeoutException: Read timed
      out".

      Please let me know if anyone has encountered this and how to resolve it.

      Thanks.
    • electric_bit
      hello , i want to ask about connection manager, i use the script bellow to test connection manager, //script var server tes.php ;
      Message 2 of 14 , Dec 7, 2006
      • 0 Attachment
        hello ,
        i want to ask about connection manager, i use the script bellow to
        test connection manager,

        //script
        var server 'tes.php';
        YAHOO.util.Connect.asyncRequest('POST', server, callback, postData);

        //File : tes.php
        <?php
        echo "<script>alert('heloo')</script>";
        ?>

        i want to run Javascript at tes.php,
        buat the response from connection manager could not handle/execute
        that javascript ....

        there's any body knows about this problem??
        thanks..
      • Thomas S. Sha
        ... Echo back the alert syntax and content, but without the script tag. Within your callback, eval the responseText result and the alert(or any JS for that
        Message 3 of 14 , Dec 8, 2006
        • 0 Attachment
          --- In ydn-javascript@yahoogroups.com, "electric_bit"
          <electric_bit@...> wrote:
          >
          > hello ,
          > i want to ask about connection manager, i use the script bellow to
          > test connection manager,
          >
          > //script
          > var server 'tes.php';
          > YAHOO.util.Connect.asyncRequest('POST', server, callback, postData);
          >
          > //File : tes.php
          > <?php
          > echo "<script>alert('heloo')</script>";
          > ?>

          Echo back the alert syntax and content, but without the script tag.
          Within your callback, eval the responseText result and the alert(or
          any JS for that matter) will execute.

          Regards,
          Thomas
        • electric_bit
          ... Work fine if the responseText only have javascript code, but if i mix the tes2.php with some html script, the eval function was not working... This is the
          Message 4 of 14 , Dec 10, 2006
          • 0 Attachment
            > Echo back the alert syntax and content, but without the script tag.
            > Within your callback, eval the responseText result and the alert(or
            > any JS for that matter) will execute.
            >
            > Regards,
            > Thomas
            >


            Work fine if the responseText only have javascript code,
            but if i mix the tes2.php with some html script, the eval function was
            not working...

            This is the example..

            //Sample script from tes1. php
            //script
            var server 'tes2.php';
            YAHOO.util.Connect.asyncRequest('POST', server, callback,
            //end of tes1.php

            //File : tes2.php
            <?php
            echo "<h3>Connection Manager</h3>
            <table border='1'><tr><td>Just testing</td></tr></table>
            alert('heloo')
            ";
            ?>
            //end of tes2.php

            The html script couldn't rendered and the js script couldn't
            executed.
            Any suggestion?
          • rasper
            Hello, are there any future plans to implement a fallback solution for IE(iframe) when ActiveX is disabled? Best regards Andreas
            Message 5 of 14 , Jan 31, 2007
            • 0 Attachment
              Hello,

              are there any future plans to implement a fallback solution for
              IE(iframe) when ActiveX is disabled?

              Best regards
              Andreas
            • tssha
              ... With IE7(and future releases) supporting XHR in JS, a fallback solution to ActiveX/IE is unlikely to happen. Connection Manager is centered around the
              Message 6 of 14 , Jan 31, 2007
              • 0 Attachment
                --- In ydn-javascript@yahoogroups.com, "rasper" <rasper@...> wrote:
                >
                > Hello,
                >
                > are there any future plans to implement a fallback solution for
                > IE(iframe) when ActiveX is disabled?
                >
                > Best regards
                > Andreas

                With IE7(and future releases) supporting XHR in JS, a fallback
                solution to ActiveX/IE is unlikely to happen.

                Connection Manager is centered around the capabilities(and
                restrictions) of the XHR object. Providing fallback mechanisms will
                provide a subset of that functionality at best, while adding to the
                code overhead.

                However, you are free to tailor the instantiation logic to your needs,
                if you desire to have a fallback.

                Regards,
                Thomas
              • dwbauer2222
                I would like to read a local file using the Connection Manager. This will never return a status of 200 (0 is the correct response); therefore I never fall
                Message 7 of 14 , May 15, 2009
                • 0 Attachment
                  I would like to read a local file using the Connection Manager. This will never return a status of 200 (0 is the 'correct' response); therefore I never fall in to the success code. But even in the failure code, why don't I have access to the xhr object?
                • learningyui
                  Hi Group, I am trying to make an AJAX call to a Perl script which returns XML using Perl s XML::Simple. When I run the Perl script directly from the command
                  Message 8 of 14 , Jul 2, 2009
                  • 0 Attachment
                    Hi Group,

                    I am trying to make an AJAX call to a Perl script which returns XML using Perl's XML::Simple.

                    When I run the Perl script directly from the command line, everything works and I see the XML code which I posted below.

                    However, I am getting nothing back on the webpage, and when I alert the (o.repsonseXML) to the screen, I get NULL.

                    Any suggestions?

                    The code is below:
                    a) Sample XML returned by Perl
                    b) The AJAX Call
                    c) The Perl code


                    a)

                    <Data>
                    <Fields>
                    <Field1>3</Field1>
                    <Field10>Name</Field10>
                    <Field2>Email</Field2>
                    <Field3>Phone</Field3>
                    </Fields>
                    </Data>


                    b)

                    var sURL = "../cgi-bin/Eric/GDFtoXML.pl";
                    var callback = {success: success_handler, failure: failure_handler, timeout: 10000};


                    function success_handler(o) {
                    document.getElementById('content').innerHTML = o.responseXML;
                    alert(o.responseXML);
                    }


                    function send_request() {
                    var callback = { success:success_handler, failure:failure_handler, timeout: 10000 };
                    YAHOO.util.Connect.asyncRequest('POST', sURL, callback);
                    }


                    c) Note: this uses XML::Simple from CPAN

                    my $xml = $xs->XMLout(\%myHash, noattr => 1, RootName=>'Data');
                    print "<?xml version='1.0' encoding='UTF-8'?>\n";
                    print "$xml";
                    return $xml;
                  • Michael Cramer
                    ... Try using Firebug in Firefox to see what s going on. If it were working properly you would see the request back to your server and a response with the XML.
                    Message 9 of 14 , Jul 2, 2009
                    • 0 Attachment
                      --- In ydn-javascript@yahoogroups.com, "learningyui"
                      > I am trying to make an AJAX call to a Perl script which returns XML using Perl's XML::Simple.
                      >
                      > When I run the Perl script directly from the command line, everything works and I see the XML code which I posted below.
                      >
                      > However, I am getting nothing back on the webpage, and when I alert the (o.repsonseXML) to the screen, I get NULL.

                      Try using Firebug in Firefox to see what's going on. If it were working properly you would see the request back to your server and a response with the XML. If your URL is wrong, Firebug should show the 404. If you get a 200, but incorrect or missing data, you might be passing bad arguments to the script. If you see a 500, chances are your script is failing to set the appropriate headers (like "Content-type:").

                      With Firebug you'll at least be able to see the transaction and any errors coming back from the server.

                      http://getfirebug.com/

                      --Mike
                    • John Doe
                      I am getting the proper response when looking at Firebug, and as for the headers: i am getting Content-Typetext/xml; which I believe is CORRECT. Any other
                      Message 10 of 14 , Jul 2, 2009
                      • 0 Attachment
                        I am getting the proper response when looking at Firebug, and as for the headers: i am getting

                        Content-Type text/xml;

                        which I believe is CORRECT.

                        Any other ideas?


                        From: Michael Cramer <cramer@...>
                        To: ydn-javascript@yahoogroups.com
                        Sent: Thursday, July 2, 2009 11:14:37 AM
                        Subject: [ydn-javascript] Re: Connection Manager

                        --- In ydn-javascript@ yahoogroups. com, "learningyui"

                        > I am trying to make an AJAX call to a Perl script which returns XML using Perl's XML::Simple.
                        >
                        > When I run the Perl script directly from the command line, everything works and I see the XML code which I posted below.
                        >
                        > However, I am getting nothing back on the webpage, and when I alert the (o.repsonseXML) to the screen, I get NULL.

                        Try using Firebug in Firefox to see what's going on. If it were working properly you would see the request back to your server and a response with the XML. If your URL is wrong, Firebug should show the 404. If you get a 200, but incorrect or missing data, you might be passing bad arguments to the script. If you see a 500, chances are your script is failing to set the appropriate headers (like "Content-type: ").

                        With Firebug you'll at least be able to see the transaction and any errors coming back from the server.

                        http://getfirebug. com/

                        --Mike


                      • Michael Cramer
                        ... Maybe try o.responseText instead of o.responseXML ? Also, console.log(o) might be helpful in your callbacks to see what YUI is getting back from the
                        Message 11 of 14 , Jul 2, 2009
                        • 0 Attachment
                          On Thu, Jul 2, 2009 at 11:25 AM, John Doe<learningyui@...> wrote:
                          > I am getting the proper response when looking at Firebug, and as for the
                          > headers: i am getting
                          >
                          > Content-Type text/xml;
                          >
                          > which I believe is CORRECT.
                          >
                          > Any other ideas?

                          Maybe try "o.responseText" instead of "o.responseXML"? Also,
                          "console.log(o)" might be helpful in your callbacks to see what YUI is
                          getting back from the request.

                          --
                          Mike Cramer
                          http://www.webkist.com/
                          215.769.2505 // AIM/Skype/Etc: MikeWebkist
                        • John Doe
                          I have tried the o.responseText and that does not really work for me - I am getting back only the most intenal leaves/data, no XML structure, and getting it
                          Message 12 of 14 , Jul 2, 2009
                          • 0 Attachment
                            I have tried the o.responseText and that does not really work for me - I am getting back only the most intenal leaves/data, no XML structure, and getting it all back as one long and ugly string.

                            I need to maintain the XML structure for later accessing of the data.

                            I also get:



                            From: Michael Cramer <cramer@...>
                            To: ydn-javascript@yahoogroups.com
                            Sent: Thursday, July 2, 2009 11:32:20 AM
                            Subject: Re: [ydn-javascript] Re: Connection Manager

                            On Thu, Jul 2, 2009 at 11:25 AM, John Doe<learningyui@ yahoo.com> wrote:
                            > I am getting the proper response when looking at Firebug, and as for the
                            > headers: i am getting
                            >
                            > Content-Type text/xml;
                            >
                            > which I believe is CORRECT.
                            >
                            > Any other ideas?

                            Maybe try "o.responseText" instead of "o.responseXML" ? Also,
                            "console.log( o)" might be helpful in your callbacks to see what YUI is
                            getting back from the request.

                            --
                            Mike Cramer
                            http://www.webkist. com/
                            215.769.2505 // AIM/Skype/Etc: MikeWebkist


                          • Satyam
                            A single whitespace, otherwise invisible before the
                            Message 13 of 14 , Jul 2, 2009
                            • 0 Attachment
                              A single whitespace, otherwise invisible before the <?xml declaration
                              (which you don't show in the XML sample though it seems you are
                              outputting from the code) will make it fail. The <?xml processing
                              instruction should be the very first thing in the message and it has to
                              be there. Browsers often strip it before processing because browsers
                              are designed to be tolerant. JavaScript does not because it is up to
                              you to decide what to do, whether to be tolerant or not. That means
                              that those nasty whitespaces are often hard to see. Do something like

                              alert('[' + o.responseText.replace(/\s/g,'.') ); to see if there is any
                              such whitespace.

                              Satyam


                              John Doe escribió:
                              >
                              >
                              > I am getting the proper response when looking at Firebug, and as for
                              > the headers: i am getting
                              >
                              > Content-Type text/xml;
                              >
                              > which I believe is CORRECT.
                              >
                              > Any other ideas?
                              >
                              > ------------------------------------------------------------------------
                              > *From:* Michael Cramer <cramer@...>
                              > *To:* ydn-javascript@yahoogroups.com
                              > *Sent:* Thursday, July 2, 2009 11:14:37 AM
                              > *Subject:* [ydn-javascript] Re: Connection Manager
                              >
                              > --- In ydn-javascript@ yahoogroups. com
                              > <mailto:ydn-javascript%40yahoogroups.com>, "learningyui"
                              > > I am trying to make an AJAX call to a Perl script which returns XML
                              > using Perl's XML::Simple.
                              > >
                              > > When I run the Perl script directly from the command line,
                              > everything works and I see the XML code which I posted below.
                              > >
                              > > However, I am getting nothing back on the webpage, and when I alert
                              > the (o.repsonseXML) to the screen, I get NULL.
                              >
                              > Try using Firebug in Firefox to see what's going on. If it were
                              > working properly you would see the request back to your server and a
                              > response with the XML. If your URL is wrong, Firebug should show the
                              > 404. If you get a 200, but incorrect or missing data, you might be
                              > passing bad arguments to the script. If you see a 500, chances are
                              > your script is failing to set the appropriate headers (like
                              > "Content-type: ").
                              >
                              > With Firebug you'll at least be able to see the transaction and any
                              > errors coming back from the server.
                              >
                              > http://getfirebug. com/ <http://getfirebug.com/>
                              >
                              > --Mike
                              >
                              >
                              >
                              >
                              >
                              > ------------------------------------------------------------------------
                              >
                              >
                              > No virus found in this incoming message.
                              > Checked by AVG - www.avg.com
                              > Version: 8.5.375 / Virus Database: 270.13.2/2214 - Release Date: 07/02/09 05:54:00
                              >
                              >
                            • Singh, Amit IN BLR SISL
                              Hi I am using YAHOO.example.container.wait panel. But when it appears All dropdown box es are becoming invisible. Any idea to fix it. Thanks
                              Message 14 of 14 , Sep 9, 2009
                              • 0 Attachment

                                Hi

                                I am using YAHOO.example.container.wait panel. But when it appears  

                                All dropdown boxes are becoming invisible.

                                Any idea to fix it.

                                Thanks

                                 

                                 

                                 

                              Your message has been successfully submitted and would be delivered to recipients shortly.