The script that is making the ajax request has to be on the same domain
where the ajax response is coming from. So just keep your script on your
server and use a wrapper function from the other domain that calls your
script residing on your domain.
On Tue, Sep 16, 2008 at 12:23 PM, Diodeus [EMAIL
[EMAIL PROTECTED] wrote:
No, I want after changing the Select1 call an Event whitch will caught
by Select2 and do somth with Select2
On 29 сент, 18:50, Hector Virgen [EMAIL PROTECTED] wrote:
I'm not too sure, but I think it's because you need to observe the event
where the event is fired
I'm not too sure, but I think it's because you need to observe the event
where the event is fired. $('Select1') fires the event, so you need to
observe $('Select1') to catch the event, otherwise you're waiting for
$('Select2') to fire it, and it never does.
2008/9/28 buda [EMAIL PROTECTED]
but
Very nice! I'd like to see this added to Scriptaculous.
On Thu, Oct 2, 2008 at 10:38 AM, dinken [EMAIL PROTECTED] wrote:
Bug with Autocompleter not canceling pending Ajax requests causing
potential race condition for onComplete logic.
//I added this function to the Ajax.Autocompleter class
Do any callbacks exists for when an element is removed from the DOM via
Element.remove()? Or maybe a custom event can be called just prior to the
removal? I need something like this to help me remove related tooltip divs
that are not direct descendants of the element being removed.
For example,
Very nice! I think that covers it for my current needs. Thanks :)
-Hector
On Mon, Oct 6, 2008 at 1:11 PM, Justin Perkins [EMAIL PROTECTED]wrote:
You can use Function#wrap to help you with this by wrapping the
Element#remove method, but you will also have to watch out for other
destructive
Is there a vertical equivalent to Effect.Shake, or a way to make it shake
vertically instead of horizontally?
-Hector
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
Prototype script.aculo.us group.
To post to this
Is there a Prototype way to get the descendants of an element that are only
text nodes? Element.descendents() only returns elements. Thanks!
-Hector
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
Prototype
]wrote:
This might not work in IE, as IE doesn't return textnodes in childNodes.
/Søren
On 07/10/2008, at 21.24, Hector Virgen wrote:
Thanks! That should do the trick :)
On Tue, Oct 7, 2008 at 12:12 PM, Justin Perkins [EMAIL PROTECTED]wrote:
I think you will need to use the native methods
Correction (but still untested):
$$('a.ajaxable').invoke('observe', 'click', handleAjaxClick);
-Hector
On Wed, Oct 8, 2008 at 11:09 AM, Hector Virgen [EMAIL PROTECTED] wrote:
I'm not sure how you'd do this with CakePHP's helper, but I think the basic
idea is you want to set up an observer
will need to use either a
smarter selector or a test inside the loop to only return the non-
child portion of the element.
Walter
On Oct 8, 2008, at 11:31 AM, Hector Virgen wrote:
Maybe there's a better way to approach my problem.
I have a nested unordered list that contains
The problem is that each of your input boxes have the same ID. All instance
of the Autocompleter are being attached to that ID, and the DOM only returns
the first one.
On Wed, Oct 8, 2008 at 12:42 PM, kevandju [EMAIL PROTECTED] wrote:
Example of what HTML looks like if a user chooses to add 3
support.
On Thu, Oct 9, 2008 at 3:53 PM, Hector Virgen [EMAIL PROTECTED] wrote:
Is there a reason you need the data to remain escaped while being used by
javascript? Unless your javascript is interacting directly with the
database, you should not need to keep your data escaped. Once javascript
or single quotes.
On Thu, Oct 9, 2008 at 4:38 PM, Hector Virgen [EMAIL PROTECTED] wrote:
Maybe I'm not understanding your implementation, but why do the quotes
have to be escaped? If you are passing the data to a function, and is
already in the form of a variable, then you do not need
coming from the server via an ajax interaction
and not on a page load.
I can certainly post code, but maybe I was more clear about the situation
here.
On Thu, Oct 9, 2008 at 4:58 PM, Hector Virgen [EMAIL PROTECTED] wrote:
Why are you printing the variable contents instead of using
Would it be better to receive text nodes as an enumerable? Maybe something
like Element#childTextNodes() to compliment Element#childElements()? It
would be nice if text nodes that contain only white space are excluded.
-Hector
On Thu, Oct 9, 2008 at 8:56 PM, Justin Perkins [EMAIL PROTECTED]wrote:
When the script element is inserted into the document body, does the
currently-running script wait for the js file to be downloaded and executed?
Or does the js file download in the background while the current script
finishes?
-Hector
2008/10/15 buda [EMAIL PROTECTED]
tere is a beautifull
Try using Element#scrollTo
http://prototypejs.org/api/element/scrollto
$('content').scrollTo();
On Thu, Oct 30, 2008 at 10:58 PM, Ali Imran Ahmad
[EMAIL PROTECTED]wrote:
Hi, i am developing myspace application. I have a form which has large
height so when i post data through ajax request it
Hello,
Is it possible to convert elements / text nodes to JSON using
Object.toJSON()? I need them in JSON so I can store them in a cookie for the
cookiejar class I am creating.
sample code:
var element = new Element('div');
var nativeelement = document.createElement('div');
var textnode =
7, 2:19 pm, Hector Virgen [EMAIL PROTECTED] wrote:
Hello,
Is it possible to convert elements / text nodes to JSON using
Object.toJSON()? I need them in JSON so I can store them in a cookie for
the
cookiejar class I am creating.
sample code:
var element = new Element('div');
var
, 11:54 pm, Hector Virgen [EMAIL PROTECTED] wrote:
Sorry if this has been asked before, but is there an updated list of
browsers and versions supported by Prototype? I'm particularly interested
in
slightly-older Mac-based browsers like IE5.5 and Safari 2. Thanks!
-Hector
. Crowder [EMAIL PROTECTED]wrote:
Hi,
Does anyone know if IE 5.5 for the Mac is supported?
IE 5.5 for the Mac isn't even supported by Microsoft. :-) They EOL'd
it a couple of years ago.
--
T.J. Crowder
tj / crowder software / com
On Nov 14, 4:08 pm, Hector Virgen [EMAIL PROTECTED] wrote
I believe Element#insert() expects an object as its parameter, like this:
$('tableid').down('tbody').insert({top: tr});
http://prototypejs.org/api/element/insert
-Hector
On Wed, Nov 19, 2008 at 8:27 AM, jason maina [EMAIL PROTECTED] wrote:
Hi,
As per the subject i'm building DOM elements
A prototype way might go something like this (untested):
var focused;
Event.observe(document, 'dom:loaded', function()
{
$$('input, select, textarea').invoke('observe', 'focus', function(event)
{
focused = event.element();
});
});
-Hector
On Wed, Nov 19, 2008 at 7:50 AM,
On Wed, Nov 19, 2008 at 8:07 PM, kangax [EMAIL PROTECTED] wrote:
On Nov 19, 3:39 pm, Hector Virgen [EMAIL PROTECTED] wrote:
A prototype way might go something like this (untested):
var focused;
Event.observe(document, 'dom:loaded', function()
{
$$('input, select, textarea').invoke
Is it possible to override Element#observe to do this automatically?
-Hector
On Fri, Nov 21, 2008 at 10:26 AM, Matt Foster [EMAIL PROTECTED]wrote:
To elaborate on Kangax's idea, a DOM element is a dynamic object,
being that you can add custom properties which can be referenced for
further
When you create an element with new Element(), it only exists as a
javascript variable until you append the element to the DOM.
The $() function looks in the DOM for the element, which is why it is not
finding it.
Also, you may want to use Element#setStyle() instead of accessing the style
This is untested, but I would probably do something like this:
$$('form[name=login_form]').invoke('observe', 'keydown', function(event)
{
if (event.keyCode === 13) {
event.findElement('form').submit();
}
});
-Hector
On Wed, Dec 10, 2008 at 4:46 AM, Dave L [EMAIL PROTECTED]
I suggest using a class name of required instead of creating a new
attribute. Then it becomes very simple to select() required elements (no to
mention styling them with CSS).
div.select('select.required');
-Hector
On Wed, Dec 17, 2008 at 9:35 AM, buda www...@pochta.ru wrote:
sorry - I do
Wow, so only robot programmers can write a $() function?
-Hector
On Fri, Jan 23, 2009 at 12:16 PM, kangax kan...@gmail.com wrote:
On Jan 23, 3:00 pm, Gabriel Gilini gabr...@usosim.com.br wrote:
Quoting the Ecma-262:
This standard specifies one departure from the grammar given in the
Thanks for the clarification. I assumed that the attribute would be the same
as the element property, but I see now how they can be different.
-Hector
On Mon, Feb 23, 2009 at 8:15 AM, SWilk wilkola...@gmail.com wrote:
Hector Virgen wrote:
Hello,
I am writing a plugin that takes a text
Check out Class#create
http://prototypejs.org/api/class/create
It's a great way to get started with OO javascript.
-Hector
On Fri, Feb 27, 2009 at 3:43 PM, greghauptmann greg.hauptm...@gmail.comwrote:
Hi all,
I confess this is a newbie question in advance:
Q1 - If one wants to build a
Also, here's a shameless plug to my own blog that showcases a simple OO
prototype plugin. However, it doesn't use Class#create :(
http://www.virgentech.com/code/prototagger
-Hector
On Fri, Feb 27, 2009 at 5:16 PM, Hector Virgen djvir...@gmail.com wrote:
Check out Class#create
http
event.element() may not necessarily return $('object_id'). It returns the
element that fired the event, which can be a child element of
$('object_id').
For example:
Event.observe('document', 'click', function(event)
{
console.log('You clicked on: ', event.element());
});
If you look at the
Typo in my JS snippet... there should be no quotes around document
Event.observe(document, 'click', function(event)
{
console.log('You clicked on: ', event.element());
});
-Hector
On Thu, Mar 26, 2009 at 4:35 PM, Hector Virgen djvir...@gmail.com wrote:
event.element() may not necessarily
$$() uses CSS selectors, so you must pass in a CSS rule. Try this:
$$('a.classProjectsEditA').invoke('observe', 'click', editProjectRecord);
-Hector
On Wed, Apr 1, 2009 at 8:47 AM, BrentNicholas brentnicho...@gmail.comwrote:
Hello all,
I found that the getElementsByClassName had been
Can you use the native parseInt() function? or parseFloat()?
var num = parseInt(52);
console.log(num); // int 52
-Hector
On Fri, Apr 24, 2009 at 9:06 AM, Ananth Raghuraman
araghuram...@gmail.comwrote:
Need prototype function to convert object/string/number to number. Please
help.
It seems like you're working against the standard here. Normally, the value
is what's important upon submission.
But what you want can be done. There are two approaches to this:
1. When rendering the page, make the value and description the same. You'll
need to escape the value attribute with
38 matches
Mail list logo