[Proto-Scripty] making Form.Observer return the updated element

2009-04-29 Thread louis w
Problem that I have always had with the Form.Observer is that it doesn't return the form element which was updated, just the actual form. Not that useful. While back I got the code below from someone (I think on this Google Group) which will return the element, however it doesn't work on forms

[Proto-Scripty] Re: making Form.Observer return the updated element

2009-04-29 Thread louis w
Actually it's not radios that are causing the problem. It happens if there are two inputs (text, hidden, etc) which have the same name. An error I know, but it causes a loop. On Apr 29, 11:28 am, louis w louiswa...@gmail.com wrote: Problem that I have always had with the Form.Observer

[Proto-Scripty] Big problem in Form.Observe in latest stable w/ input type=file. Breaking applications.

2009-04-29 Thread louis w
Noticed a big problem between 1.6.0.2 and 1.6.0.3 with the Form.Observer. In the latest stable release (and I also checked the 'bleeding edge' release) it doesn't detect when input type=file fields are changed. This is a big problem. Does anyone have a workaround for this? DEMO: Using 1.6.0.2

[Proto-Scripty] Re: Get an array from PHP via Ajax.Request

2009-05-01 Thread louis w
You can use the json_encode php function to easily convert an array into it's json-ized counterpart which you can then send to your ajax request. http://php.net/json_encode On Apr 29, 12:13 pm, Nicholas Steicke narthol...@gmail.com wrote: Russell Keith wrote snip: When doing calling

[Proto-Scripty] Classes vs Objects - Best Practice?

2009-05-11 Thread louis w
I have always set up my Javascript using objects like below: if (!FooBar_Old) var FooBar_Old = {}; FooBar_Old.UI = { test_str : 'it works' , test: function() { console.log(this.test_str); } }; // FooBar_Old.UI.test(); However recently I have been

[Proto-Scripty] Re: Classes vs Objects - Best Practice?

2009-05-11 Thread louis w
.. though I don't use Prototypes Class method, so I'll let someone that does answer that part of the question. Josh Powell On May 11, 1:44 pm, louis w louiswa...@gmail.com wrote: I have always set up my Javascript using objects like below: if (!FooBar_Old) var FooBar_Old = {}; FooBar_Old.UI

[Proto-Scripty] Check element class against array

2009-05-13 Thread louis w
I have an array containing a number of strings. I would like to continue exucuting my script only if an item has ANY/ALL of the strings assigned as a class name. $A(['foo', 'bar', 'foob']); Is there an elegant want to do this without having to loop through the items?

[Proto-Scripty] Re: Check element class against array

2009-05-14 Thread louis w
the classes to check, was hoping there was a more elegant solution. On May 13, 11:09 pm, rai.ashis ashis@gmail.com wrote: Hi, i think you can you can use include which will return either true or false depending upon. I think this one works. Thanks On Thu, May 14, 2009 at 12:19 AM, louis w

[Proto-Scripty] Re: Check element class against array

2009-05-14 Thread louis w
of these by going under the covers. FWIW, -- T.J. Crowder tj / crowder software / com Independent Software Engineer, consulting services available On May 13, 7:34 pm, louis w louiswa...@gmail.com wrote: I have an array containing a number of strings. I would like to continue exucuting

[Proto-Scripty] Create event observer for focus?

2009-05-21 Thread louis w
Is it possible to create an event observer which will detect when a field is focused? I have tested this out by trying to assign it to the parent form (figuring the event would bubble up) however nothing happens. This is what I have: script language=javascript type=text/javascript

[Proto-Scripty] Re: Create event observer for focus?

2009-05-21 Thread louis w
('observe','focus',function(evt) { ...same as above... }); Walter On May 21, 2009, at 11:06 AM, louis w wrote: Is it possible to create an event observer which will detect when a field is focused? I have tested this out by trying to assign it to the parent form (figuring the event

[Proto-Scripty] Re: Create event observer for focus?

2009-05-21 Thread louis w
element... }); $('editForm').getInputs().invoke('observe','focus',function(evt) { ...same as above... }); Walter On May 21, 2009, at 11:06 AM, louis w wrote: Is it possible to create an event observer which will detect when a field is focused? I have tested this out by trying to assign

[Proto-Scripty] Traversing XML w/ Prototype (DOMParser)

2009-08-19 Thread louis w
Please check out the code below. I am having a hard time getting the protortype selectors to be applied to this item. Hoping to avoid having to use childNodes to parse this data. var xml = 'datastatusOK/status/data'; var parser = new DOMParser();

[Proto-Scripty] Copy event observer

2009-08-27 Thread louis w
I have a bit of javascript that replaces a text field with a bunch of html and another text field. problem is, if the original input has an event observer on it it gets thrown away, Is it possible to see if an element has an event observer and copy it to another element? Thanks.

[Proto-Scripty] New API Doc

2009-10-08 Thread louis w
Am I the only one that missed the old online api docs? This new one seems hard to use. --~--~-~--~~~---~--~~ 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

[Proto-Scripty] Re: New API Doc

2009-10-08 Thread louis w
around the site. I sure hope this is all to do with it's infancy. On Oct 8, 1:26 pm, DJ Mangus d.man...@gmail.com wrote: No. You aren't. Sent from my phone so pardon the spelling errors. On Oct 8, 2009, at 10:22 AM, louis w louiswa...@gmail.com wrote: Am I the only one that missed the old

[Proto-Scripty] Only fire event once on mouseover

2010-02-17 Thread louis w
Refer to the link below. I have a dropdown html element which has an event observer looking for mouseover. It's working, but it continuously fires mouseover events while you are mousing over the other elements inside it. I am guessing this is because of bubbling. Is there a way to only make it

[Proto-Scripty] Re: Only fire event once on mouseover

2010-02-17 Thread louis w
if the event was fired on the   parent element or on one of its children. I believe that's more or   less what the mousenter/leave observers do. Walter On Feb 17, 2010, at 4:40 PM, louis w wrote: Refer to the link below. I have a dropdown html element which has an event observer looking

[Proto-Scripty] mouseenter/leave Events in 1.6.0.3?

2010-10-05 Thread louis w
Have to make changes to a site running 1.6.0.3 and I need to be able to use the mouseenter and mouseleave event observers. Unfortunately I am not able to upgrade Prototype. Is there anyway to add a patch or a custom event listener to be able to utilize this? Any help would be great, thanks! --