unknown +ajax??????

Discussion in 'PHP' started by vetrivel, Jun 15, 2009.

  1. #1
    Hi
    while running a ajax script i am getting the statusText as UNKNOWN .

    This is not appearing all the time and it happens only in IE browser.So,How to fix this issue.
    Why i am getting this issue.Please advice me.

    And also:
    Sometime i am getting the error message as oparation aborted in IE .I need to know why this error pops up.This is appearing on page loading and also not always?


    Questions:
    ->Why this 2 error occurs .
    ->Why it occured only in IE and not in any other browser.
    ->Why it is not appearing frequently.If there is an error it should display all the times?right.But it doesn't.


    Please advice me.


    Thanks in advance .
     
    vetrivel, Jun 15, 2009 IP
  2. webwurks

    webwurks Well-Known Member

    Messages:
    126
    Likes Received:
    37
    Best Answers:
    0
    Trophy Points:
    118
    #2
    Are you using the same javascript code to send your Ajax request to the server for IE and other browsers?
    My ajax javascript code has a separate block to handle the request differently for IE.
    Microsoft is notorious for discarding standards and doing it their own way.
    If you want me to look into it further, PM me your script that handles the http request and processes the response.
     
    webwurks, Jun 15, 2009 IP
  3. ezprint2008

    ezprint2008 Well-Known Member

    Messages:
    611
    Likes Received:
    15
    Best Answers:
    2
    Trophy Points:
    140
    Digital Goods:
    1
    #3
    the main ajax application is standard .. post the rest of your code to see how youre returning the vars
     
    ezprint2008, Jun 15, 2009 IP
  4. livedating

    livedating Active Member

    Messages:
    161
    Likes Received:
    0
    Best Answers:
    1
    Trophy Points:
    83
    #4
    livedating, Jun 23, 2009 IP
  5. vetrivel

    vetrivel Peon

    Messages:
    147
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    0
    #5
    hi,
    tnks for ur posts and yes as i am using simple ajax.It dont have any error handling machanism .So prefer to go with jquery.But in previous post u have mentioned the .get(wil this only post the details in GET method.). I need it in POST method and well as provide a example to call an ajax by posting data and load the response text(html ) in to the DIV.
    Please advice me.
     
    vetrivel, Jun 25, 2009 IP
  6. vetrivel

    vetrivel Peon

    Messages:
    147
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    0
    #6
    any idea??

     
    vetrivel, Jun 28, 2009 IP
  7. livedating

    livedating Active Member

    Messages:
    161
    Likes Received:
    0
    Best Answers:
    1
    Trophy Points:
    83
    #7
    it is very simple - you can just replace it with .post :)

    you can find more info how to use it with examples here: http://docs.jquery.com/Ajax
    http://docs.jquery.com/Ajax/jQuery.post#urldatacallbacktype

    Then put it in div like this:
    
    $.post(url, post_data, function(data) {$('div#some_id').html(data); });
    
    Code (markup):
    So you define a callback response processing function and pass it to jquery post. This way to craete functions is called a "closure".

    and then in html:
    
    <div id="some_id">here will be html from POST request</div>
    
    Code (markup):
     
    livedating, Jul 2, 2009 IP