HI T.J.,

Will this work with Ajax.Request?  I changed my script so that it is created 
instead of defined and I still can't access it using evalJS.


-----Original Message-----
From: prototype-scriptaculous@googlegroups.com 
[mailto:prototype-scriptacul...@googlegroups.com] On Behalf Of T.J. Crowder
Sent: Tuesday, August 18, 2009 4:24 PM
To: Prototype & script.aculo.us
Subject: [Proto-Scripty] Re: Using Ajax.Request and evalJS to load functions on 
the fly


They're accessible from anywhere after they're evaluated, but mind how
you declare them, because of a bit of a quirk about how they're
evaluated.  There's a badly misplaced note about this in the
documentation, at the bottom of the discussion of Ajax.Updater[1].  It
really should be in the String#evalScripts documentation, and it's on
my list, but I haven't had a chance to move it.

[1] http://prototypejs.org/api/ajax/updater

T.J. Crowder
tj / crowder software / com
Independent Software Engineer, consulting services available

On Aug 18, 8:00 pm, Remah <donnie.carva...@tfmx.com> wrote:
> I am trying to call a JS file using Ajax.Request that will return a
> javascript function.  This function will be used by code taht will be
> injected into a div.  Is this possible?  It seems like the function is
> accessible within the CallBacks of Ajax.Request, but they are not
> accessible outside.
> Thanks for your help,
> Remah

You received this message because you are subscribed to the Google Groups 
"Prototype & script.aculo.us" group.
To post to this group, send email to prototype-scriptaculous@googlegroups.com
To unsubscribe from this group, send email to 
For more options, visit this group at 

Reply via email to