www.webdeveloper.com
Recent Articles
  • Finding Slow Running Queries in ASE 15
  • A More Advanced Pie Chart for Analysis Services Data
  • Adobe AIR Programming Unleashed: Working with Windows
  • Performance Testing SQL Server 2008's Change Data Capture Functionality
  • The ABC's of PHP: Introduction to PHP
  • How to Migrate from BasicFiles to SecureFiles Storage
  • Why the Twitter Haters Are Wrong
  • User Personalization with PHP: Beginning the Application
  • Whats in an Oracle Schema?
  • Lighting Enhancement in Photoshop
  •  

    Go Back   WebDeveloper.com > Client-Side Development > JavaScript

    JavaScript JavaScript (not Java) Discussion and technical support, including AJAX and frameworks (JQuery, MooTools, Prototype...)

     
     
    Thread Tools Rate Thread Display Modes
    Prev Previous Post   Next Post Next
      #1  
    Old 02-08-2010, 09:36 AM
    Mulone Mulone is offline
    Registered User
     
    Join Date: Jan 2010
    Posts: 5
    Unhappy Issue with Ajax.request + JSON

    Hi guys,
    I'm making this ajax call:

    Code:
     url = "/GeoAdaptaApp/geoLogger/logGuiEvents?json="+aLotOfJSONStuff; 
            encUrl = encodeURI(url,"UTF-8");	
    
        new Ajax.Request(encUrl, { 
               method: 'get', 
               onSuccess: this.sendQueueToServerSuccess( this,logConsole ), 
       	   onFailure: this.sendQueueToServerFailure( this,logConsole ) 
        });
    The JSON string seems correct (I checked it with a validator) and it worked on an Ajax.updater (but i need a request now).

    Firefox keeps telling me:

    Error: no element found
    Source File: http://localhost:8080/GeoAdaptaApp/geoLogger/logGuiEvents?json=%7B%22eventsQueue%22:%5B%7B%<JSON stuff>
    Line: 1

    The call always end up in the onFailure block.

    Full request here: http://tinyurl.com/y8oh968

    It's very strange, any idea about what it could be? Is there a better way to pass json objects to the server?

    Thanks,
    Mulone
    Reply With Quote
     

    Bookmarks

    Tags
    ajax, json


    Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
     
    Thread Tools
    Display Modes Rate This Thread
    Rate This Thread:

    Posting Rules
    You may not post new threads
    You may not post replies
    You may not post attachments
    You may not edit your posts

    BB code is On
    Smilies are On
    [IMG] code is Off
    HTML code is Off
    Forum Jump


    All times are GMT -5. The time now is 01:25 PM.



    Acceptable Use Policy

    Internet.com
    The Network for Technology Professionals

    Search:

    About Internet.com

    Legal Notices, Licensing, Permissions, Privacy Policy.
    Advertise | Newsletters | E-mail Offers

    Powered by vBulletin® Version 3.7.3
    Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.