The Cache: Technology Expert's Forum
 
*
Welcome, Guest. Please login or register. January 07, 2009, 07:32:11 PM

Login with username, password and session length


Pages: 1 2 [3]
  Print  
Author Topic: XMLHttpRequest, IE6, SSL , and 12030 error - what is the solution?  (Read 8278 times)
bitmap
n00b
*
Offline Offline

Posts: 1


View Profile
« Reply #30 on: April 24, 2008, 08:30:13 AM »

Well, my first post. I hope it's not the last!

I've been searching over the net for the solution of this problem in some places they say it can be solve adding some lines in server ssl.conf. I tried and isn't working either.

I've read all the posts you have in here but I didn't really understand what the solution was. I assume that i have to close the connection but I don't know where to do it

I use this xmlhttprequest file:

----------------------------------
   var request = null;

   function createRequest() {
     try {
       request = new XMLHttpRequest();
     } catch (trymicrosoft) {
       try {
         request = new ActiveXObject("Msxml2.XMLHTTP");
       } catch (othermicrosoft) {
         try {
           request = new ActiveXObject("Microsoft.XMLHTTP");
         } catch (failed) {
           request = null;
         }
       }
     }

     if (request == null)
       alert("Error creating request object!");
   }

--------------------------------------

Should I close the request here or when I make the request like:

        var url ="/blabla.php";
   createRequest();
   request.open("POST",url, true);
   request.onreadystatechange = proceselect1;
   request.setRequestHeader("Content-Type", "application/x-www-form-urlencoded");
   request.send("random="+Math.random()+"&valor="+x);
   request.setRequestHeader('Connection', 'close');

This is where goes my responseXML.

function proceselect1()
{
    if (request.readyState == 3) {
      

    }
        if (request.readyState == 4)
      {
         if(request.status == 200)
         {
            
            alert("hi);
            var resposta=request.responseXML;
         
            
         }
         else{
               
         }
      }
   
}

Well, my the alert("hi") is working but the responseXML is empty...

Sorry for my english, I'm not used to talk about technical things in english Grin
« Last Edit: April 24, 2008, 10:03:17 AM by bitmap » Logged
perkiset
Olde World Hacker
Administrator
Lifer
*****
Online Online

Posts: 5324


:sniffle: Humor was so much easier before.


View Profile
« Reply #31 on: April 24, 2008, 10:40:09 AM »

Hey bitmap, welcome to The Cache.

There really wasn't a clean one-size-fits-all solution to the problem, but what you are referencing was actually a server side thing - it is putting a "Connection: Close" header in the response packet, nothing to do with the client request. This is done in PHP, for example, like this:

header('Connection: close');

BEFORE you send anything back to the client at all - if you send even a single space back first, the header will be ignored.

Give that a shot and please report back... this line of discussion has gone rather quiet since everyone sort of made their own fixes.

/perk
Logged

If I can't be Mr. Root then I don't want to play.
Pages: 1 2 [3]
  Print  
 
Jump to:  

Perkiset's Place Home   Best of The Cache   phpMyIDE: MySQL Stored Procedures, Functions & Triggers
Politics @ Perkiset's   Pinkhat's Perspective   
cache
mart
coder
programmers
ajax
php
javascript
Powered by MySQL Powered by PHP Powered by SMF 1.1.2 | SMF © 2006-2007, Simple Machines LLC
Seo4Smf v0.2 © Webmaster's Talks


Valid XHTML 1.0! Valid CSS!