Server-Side-Processing works fine for Firefox, but not IE?

Server-Side-Processing works fine for Firefox, but not IE?

Tsun4miTsun4mi Posts: 5Questions: 0Answers: 0
edited July 2009 in General
Hi there,

i've got a problem which I still was'nt able to solve after some hours of trial & error ;-)

I've used your ssp-script to dynamically fetch data from my database and inject it into the DataTable. With Firefox, everything works perfect and exactly how it should be. With Internet Explorer 8 though, as soon as I try to initialize the table, an alert winodw pops up with the message "Warning - Added data does not match known column length". After that, it says "no results found".

It seems like an error to tell me that the JSON-Data has more columns than the table... but that's not the case.
Paradoxically, if I add another column to my HTML-Table, Firefox shows me the same error-message and IE shows nothing anymore (no message, but no data either).

Does someone figure out whats the problem is? :(

Thanks in advance,
Regards
Bernd

Replies

  • Tsun4miTsun4mi Posts: 5Questions: 0Answers: 0
    Well...as with most programming problems:
    As soon as you desperately cry for help, you find the solution yourself! ;-))

    The data in the returned JSON-feed was not properly escaped. It was ok for firefox though, but IE didn't like it.
  • allanallan Posts: 63,602Questions: 1Answers: 10,486 Site admin
    Hi Tsun4mi,

    Good to hear you got it sorted. It was most likely a trailing comma, which IE rejects, but for some reason Firefox allows. www.jsonlint.com is an outstanding tool for testing JSON validity.

    Regards,
    Allan
  • orchid1orchid1 Posts: 18Questions: 0Answers: 0
    what was the solution
    ?

    I'm having the same problem myself

    arghhhh
  • orchid1orchid1 Posts: 18Questions: 0Answers: 0
    edited August 2009
    don't hate me but I found the solution one second after I looked at me code

    heres my solution

    [code]
    $sOutput .= "[";
    $sOutput .= "'".$aRow['status']."',";
    $sOutput .= "'".$aRow['style']."',";
    $sOutput .= "'".$aRow['style']." NO Comma Necessary On the last bit of output!!!! '";
    $sOutput .= "],";
    }

    [/code]

    I put a comma
This discussion has been closed.