Hi Matt, Thanks for the response.
So when you say your solution was to use jQuery's JSON functions, do you pull in another JSON file, use the existing one, or something else. I would be awesome if you could list out the basic steps you took to solve your problem...maybe even with 1 example. I am not a JS guru by any stretch of the imagination, so I usually have to follow by example. Thanks, Bryan On Nov 5, 2:53 pm, "Penner, Matthew" <[EMAIL PROTECTED]> wrote: > Hi Bryan, > > We had this problem as well. The solution was to use jQuery's JSON > functions $.toJSON() & .parseJSON() instead of those built into the JSON > library. > > Matt Penner > > -----Original Message----- > From: jquery-en@googlegroups.com [mailto:[EMAIL PROTECTED] On > Behalf Of Bryank > Sent: Monday, November 05, 2007 8:39 AM > To: jQuery (English) > Subject: [jQuery] JSON + JQUERY Problem! Need help ASAP toJSONString not > a function > > Hi Everyone, > > First time poster on this group. We use JSON for various projects and > one thing I am beginning to implement are some Jquery lightbox > effects. > > Well, sure enough Jquery and JSON don't play nice in this regard. If I > try one of the JSON No Augmenting JS files out on the web, that breaks > the rest of our functionality that uses JSON. > > It typically barfs on a line that has "something.toJSONString" and > says it is not a function. > > here is a snippet of example code. On th eline with postBody, it > breaks. > > if (onException == null) > onException = onExceptionDefault; > var ajax = new Ajax.Request( > url, > { > method: 'post', > parameters: '', > postBody: "msg={ 'blahEvent' : " + > encodeURIComponent(blahEvent.toJSONString()) + "}", <==== IT BARFS > HERE!!! > // postBody: "msg={'blahEvent' : " + blahEvent.toJSONString() + > "}", > onComplete: onComplete, > onFailure: onFailure, > onException: onException, > asynchronous: curAsync > }); > > Here is the FireBug output for the error: If you look closely on > exceptionHappened, there are 2 undefined's. > > ===================FIREBUG OUTPUT=========================== > _makeRequest(Object _type=ajaxGetEvents type=ajaxGetEvents, > eventsReceived(r), false, exceptionHappened(requestor, ex, > doRedirect), undefined, undefined)gapsession.js (line 781) > getBlahEvents()gapsession.js (line 717) > getEventLoop()gapsession.js (line 23) > handlePageLoad()idle.action# (line 172) > onload(load ) > ============================================================= > > If I download one of the JSON plugins for Jquery as a solution, can > you provide me an example of the code I just posted with the fix > attached to it? > > Thanks, > Bryan