[Proto-Scripty] Re: Proposal for improving bind() + adding "unbind()" support

2009-03-11 Thread kangax
On Mar 11, 11:29 am, Robert Kieffer wrote: [...] > @kangax, re: use of $A, shift, apply - Sure, there's room for other > performance tweaks, but what I care most about is the performance of > invoking a bound function, not in the construction of a bound > function.  This is why the function that

[Proto-Scripty] Re: Custom data- attributes and css select syntax

2009-03-11 Thread kangax
On Mar 11, 5:09 pm, Tom wrote: > I was wondering if there were any plans to address the .select ($$) > syntax in respect to the custom data- attributes available for html5. > Right now I get errors trying to so something like $$('li[data- > mything]') something I believe is caused by using the hy

[Proto-Scripty] Re: Mass AJAX Requests

2009-03-11 Thread Akshit Soota
Thanks a lot ~!! On Mar 11, 9:16 pm, "T.J. Crowder" wrote: > Hi, > > Frankly, again, you're not doing much to help us help you here.  We > can't magically see what you're doing and then tell you what's wrong > with it. > > Ryan's right, of course, that the most efficient thing would be to > proc

[Proto-Scripty] Re: latest scriptaculous functional and unit tests fail in IE7.0 and unit tests fail in FF3.0.7

2009-03-11 Thread krishna
After two full days of debugging using alerts and console prints in IE7.0 and not giving up, I found that there is some piece of code which when removed, worked for me in both IE and FF even when used inside one of the frames! I wish someone could explain me the IE thingy here! search for CHANGES

[Proto-Scripty] Re: Proposal for improving bind() + adding "unbind()" support

2009-03-11 Thread Tobie Langel
On Mar 11, 7:38 pm, Robert Kieffer wrote: > Yeah, it's a nice little trick.  And, yes, it does look a little > fishy, but I couldn't think of any reason why it wouldn't work. For it not to work you would need the two following conditions: 1. Function.prototype.apply passing it's second argume

[Proto-Scripty] Custom data- attributes and css select syntax

2009-03-11 Thread Tom
I was wondering if there were any plans to address the .select ($$) syntax in respect to the custom data- attributes available for html5. Right now I get errors trying to so something like $$('li[data- mything]') something I believe is caused by using the hyphen in the select syntax. Has there bee

[Proto-Scripty] Re: Ajax.Updater home-brew autocompletion timing issue

2009-03-11 Thread Richard Quadling
2009/3/11 Richard Quadling : > The response does not have access to the request. I created the ticket > for this a long time ago, but I can't establish if there is any > memleak when the response includes the request. > > http://dev.rubyonrails.org/ticket/9691 > > Over a year old ticket. > This i

[Proto-Scripty] Re: Ajax.Updater home-brew autocompletion timing issue

2009-03-11 Thread Richard Quadling
The response does not have access to the request. I created the ticket for this a long time ago, but I can't establish if there is any memleak when the response includes the request. http://dev.rubyonrails.org/ticket/9691 Over a year old ticket. 2009/3/11 Jonny Nott : > > Thanks for that link

[Proto-Scripty] Re: Ajax.Updater home-brew autocompletion timing issue

2009-03-11 Thread Alex Mcauley
Can you report the question again as it seems to be missing Thanks Alex - Original Message - From: "Jonny Nott" To: "Prototype & script.aculo.us" Sent: Wednesday, March 11, 2009 7:57 PM Subject: [Proto-Scripty] Re: Ajax.Updater home-brew autocompletion timing issue > > Thanks for th

[Proto-Scripty] Re: Ajax.Updater home-brew autocompletion timing issue

2009-03-11 Thread Jonny Nott
Thanks for that link Alex. However, as I've tried to proceed with this, I keep coming back to needing answers to my two original questions. Can anyone assist? The questions: - Which callback will allow me to intercept Ajax.updater at this point? Will this even work with Ajax.updater, or do I ne

[Proto-Scripty] Re: img disable & enable

2009-03-11 Thread Richard Quadling
2009/3/11 laurin1 : > > Why does Prototype through and error when trying to disable an img? It > says that object does not support property or method. However, I can > enable and disable the img element via HTML without a problem. > > > Here is an updated demo for something I wrote to help someon

[Proto-Scripty] img disable & enable

2009-03-11 Thread laurin1
Why does Prototype through and error when trying to disable an img? It says that object does not support property or method. However, I can enable and disable the img element via HTML without a problem. --~--~-~--~~~---~--~~ You received this message because you are

[Proto-Scripty] Re: Proposal for improving bind() + adding "unbind()" support

2009-03-11 Thread Robert Kieffer
@Tobie: "[*Evil Cackle*]... You just now noticed that, did you?" Yeah, it's a nice little trick. And, yes, it does look a little fishy, but I couldn't think of any reason why it wouldn't work. I've updated the blog post to include your implementation in the tests. (BTW, please note that if you

[Proto-Scripty] Re: is there any problem with RegExp??

2009-03-11 Thread Tobie Langel
You shouldn't be using for... in to iterate over an array, see: http://proto-scripty.wikidot.com/prototype:tip-looping-through-arrays On Mar 11, 7:26 pm, eulerss wrote: > ok, here is my code of my function on javascript only, i dont know if > its causing some conflict > > function filtr2(){ > >

[Proto-Scripty] Re: is there any problem with RegExp??

2009-03-11 Thread eulerss
ok, here is my code of my function on javascript only, i dont know if its causing some conflict function filtr2(){ gr=document.pedido.elements['tipo_final']; grval=gr.options[gr.selectedIndex].value; gr2=document.pedido.elements['marca_final']; grval2=gr2.options

[Proto-Scripty] Re: Proposal for improving bind() + adding "unbind()" support

2009-03-11 Thread Ryan Gahl
Has that been tested with deferral? Ryan Gahl CEO Nth Penguin, LLC http://www.nthpenguin.com -- Inquire: 1-920-574-2218 Blog: http://www.someElement.com LinkedIn Profile: http://www.linkedin.com/in/ryangahl On Wed, Mar 11, 2009 at 1:13 PM, Tobie Langel wrote: > > Actually, Robert, I took a clo

[Proto-Scripty] Re: Proposal for improving bind() + adding "unbind()" support

2009-03-11 Thread Tobie Langel
Actually, Robert, I took a closer look at your implementation. And I figured out why it's so much faster. You're relying on a single array of partially applied arguments whose length you reset rather than cloning the array each time. This actually turns out to be perfectly spec-compliant and av

[Proto-Scripty] Re: Scrolling Tables

2009-03-11 Thread Lee Jenkins
Richard Quadling wrote: > > Looks lovely in FireFox. > > Really nice. > > In Chrome, nope. Looking at the computed style for the tbody, > overflow-y is visible rather than scroll. I even tried inlining the > style. The height is ignored also. > > In IE7, well. What a nice big cell you have the

[Proto-Scripty] Re: is there any problem with RegExp??

2009-03-11 Thread Tobie Langel
Short answer: No. For a longer answer to your particular problem, you'll have to provide more code. :) Best, Tobie --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Prototype & script.aculo.us" group. To post to thi

[Proto-Scripty] Re: Proposal for improving bind() + adding "unbind()" support

2009-03-11 Thread Tobie Langel
Your results look impressive indeed. However, I'd like to ponder code source readability and maintainability with performance (which was the main goal of the recent changes). Could you maybe benchmark this: function bind(context) { var __method = this, args; if (arguments.length

[Proto-Scripty] is there any problem with RegExp??

2009-03-11 Thread eulerss
Hi all, my problem is that i use RegExp in javascript in order to refresh one combobox from an input, something like this: exreg= new RegExp(my_vay,"i"); array[sub]['ITEM'].search(exreg)==0 etc, etc, and it works, but when i add prototype library now it doesnt work, and the error is on line

[Proto-Scripty] Re: Proposal for improving bind() + adding "unbind()" support

2009-03-11 Thread T.J. Crowder
Hi, > That's true, but your example does not use .bind(), therefore I don't > really see how it pertains to the discussion. I was addressing your question (the one I quoted), not the bind discussion. > When you .bind(), you are > passing the the function to bind, along with it's context and al

[Proto-Scripty] Re: Scrolling Tables

2009-03-11 Thread Richard Quadling
Me too. http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd";> http://www.w3.org/1999/xhtml";> Scrolling tbody /**/ Famil

[Proto-Scripty] Re: latest scriptaculous functional and unit tests fail in IE7.0 and unit tests fail in FF3.0.7

2009-03-11 Thread krishna
David, It is the newbie again, I have updated all of my javascript files and found that nothing changed, I still see the issue: Ajax.Autocompleter blanks out the page (frame only) when used in an Internet Explorer IE 7.0.5730.11 framed jsp! I created a dummy web application and sent you the link

[Proto-Scripty] Re: Scrolling Tables

2009-03-11 Thread Brendan O Connor
yup thats what i do aswell 2009/3/11 Ryan Gahl > Have you tried using thead and tbody, and placing the overflow setting on > the tbody? > > Ryan Gahl > CEO > Nth Penguin, LLC > http://www.nthpenguin.com > -- > Inquire: 1-920-574-2218 > Blog: http://www.someElement.com

[Proto-Scripty] Re: Scrolling Tables

2009-03-11 Thread Ryan Gahl
Have you tried using thead and tbody, and placing the overflow setting on the tbody? Ryan Gahl CEO Nth Penguin, LLC http://www.nthpenguin.com -- Inquire: 1-920-574-2218 Blog: http://www.someElement.com LinkedIn Profile: http://www.linkedin.com/in/ryangahl On Wed, Mar 11, 2009 at 11:21 AM, Lee Je

[Proto-Scripty] Scrolling Tables

2009-03-11 Thread Lee Jenkins
Hi all, I'm trying to implement a scrolling table myself since my needs are very simple. I'm placing the table that represents the grid cells within a div with overflow:auto set and it scrolls. However, IE and FF seem to calculate the width differently in regard to the scrollbars that app

[Proto-Scripty] latest scriptaculous functional and unit tests fail in IE7.0 and unit tests fail in FF3.0.7

2009-03-11 Thread krishna
Ran the autoupdater functional test and autoupdater unit tests in FF3.0.7 and IE7.0 and saw the unit tests failing in both IE and FF :( scriptaculous-js-1.8.2\test\run_functional_tests.html scriptaculous-js-1.8.2\test\run_unit_tests.html and found that functional test passed in FF only, every th

[Proto-Scripty] Re: Proposal for improving bind() + adding "unbind()" support

2009-03-11 Thread Ryan Gahl
What I meant to say was, you didn't compare the first example of inlining to another example using bind. I get that in general you were just illustrating the closure behaviors... Ryan Gahl CEO Nth Penguin, LLC http://www.nthpenguin.com -- Inquire: 1-920-574-2218 Blog: http://www.someElement.com L

[Proto-Scripty] Re: Mass AJAX Requests

2009-03-11 Thread T.J. Crowder
Hi, Frankly, again, you're not doing much to help us help you here. We can't magically see what you're doing and then tell you what's wrong with it. Ryan's right, of course, that the most efficient thing would be to process the entire list on the server. Of course, there are reasons not to do

[Proto-Scripty] Re: Proposal for improving bind() + adding "unbind()" support

2009-03-11 Thread Ryan Gahl
> > If we recast our example to use a named function for the handler: > > function init() { >var container; > >container = $('container'); >hookUpHideables(container); >container.show(); > >function hookUpHideables(p) { >p.select('.hideable').invoke('observe', 'click', h

[Proto-Scripty] Re: Mass AJAX Requests

2009-03-11 Thread Richard Quadling
2009/3/11 Akshit Soota : > > Okay so I replied once but replying the 2nd time to ask you a code > suggestion of Prototype JS AJAX. I have an array of emails and then > give me the code to send the emails via a specific PHP Page ! > > On Mar 11, 6:57 pm, "T.J. Crowder" wrote: >> Hi, >> >> Fails ho

[Proto-Scripty] Re: Proposal for improving bind() + adding "unbind()" support

2009-03-11 Thread Robert Kieffer
*Darn* 'Just noticed a bug in my test suite. I've just rejiggered the tests and updated the blog post. The results are more varied/ intersting than before, but still show significant improvements. better than the current prototype implementation. Anyone care to explain the FF behavior when pass

[Proto-Scripty] Re: Proposal for improving bind() + adding "unbind()" support

2009-03-11 Thread Ryan Gahl
> > [Wow, wasn't expecting such a barrage of (great) responses! (I get > this list in digest mode, so find myself scrambling to catch up > here.)] That tends to happen here :) Rob, those are some VERY impressive numbers you put up in that blog post. I absolutely have to avoid the mailing list t

[Proto-Scripty] Re: Ajax.Autocompleter blanks out page when used in an Internet Explorer IE framed jsp

2009-03-11 Thread krishna
David, I sent you a link using "Reply to author" as per your request and will now download the latest scriptaculous and test it! Also, I see that there are other CSS issues which I will discuss once I finish this! --~--~-~--~~~---~--~~ You received this message bec

[Proto-Scripty] Re: Ajax.Autocompleter blanks out page when used in an Internet Explorer IE framed jsp

2009-03-11 Thread krishna
David, I posted the link as per your request and will now download the latest scriptaculous and test it! --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Prototype & script.aculo.us" group. To post to this group, send

[Proto-Scripty] Re: Mass AJAX Requests

2009-03-11 Thread Tobie Langel
Serialize your array, or pass it through Object.toJSON() and handle the dispatching server side. Best, Tobie --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Prototype & script.aculo.us" group. To post to this gr

[Proto-Scripty] Re: Proposal for improving bind() + adding "unbind()" support

2009-03-11 Thread Robert Kieffer
[Wow, wasn't expecting such a barrage of (great) responses! (I get this list in digest mode, so find myself scrambling to catch up here.)] Regarding performance stats: I've just posted some test data over on my blog... http://www.broofa.com/blog/2009/03/prototype-bind-performance Basically, it

[Proto-Scripty] Re: Mass AJAX Requests

2009-03-11 Thread Akshit Soota
Okay so I replied once but replying the 2nd time to ask you a code suggestion of Prototype JS AJAX. I have an array of emails and then give me the code to send the emails via a specific PHP Page ! On Mar 11, 6:57 pm, "T.J. Crowder" wrote: > Hi, > > Fails how?  Which part is failing?  What is the

[Proto-Scripty] Re: Mass AJAX Requests

2009-03-11 Thread Akshit Soota
In fact I send a loop at once, sending all the AJAX requests !! On Mar 11, 6:57 pm, "T.J. Crowder" wrote: > Hi, > > Fails how?  Which part is failing?  What is the error?  Are you > overlapping the requests, or sending them serially?  What have you > already looked into?  How have you tried to i

[Proto-Scripty] Re: Drag and drop - using it with a form and a database

2009-03-11 Thread Marian Briones
Hmm I tried the code and it didn't do any kind of drag and drop (and yes I am using scriptaculous) On Tue, Mar 10, 2009 at 6:07 PM, Marian Briones wrote: > How do I put the result there? JavaScript? That's what I was thinking; > that it had to come somehow in a hidden field... > > THanks

[Proto-Scripty] Re: Download page via prototype. with making all scripts on page. Help with code.

2009-03-11 Thread ColinFine
On Mar 11, 11:21 am, david wrote: > btw, the initialisation of the Ajax.update is strange, it should be: > new Ajax.Updater(container, url, {options}) > > and for you the container parameter is {success: 'placeholder'} ?? > > shouldn't it be: var myAjax = new Ajax.Updater( 'placeholder', url,

[Proto-Scripty] Re: Mass AJAX Requests

2009-03-11 Thread Ryan Gahl
> > I call a PHP Page !! That's your error :) (kidding, of course) ... As TJ said, we need more than details than "I'm trying to do X, and it's not working, what do I do??" --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google

[Proto-Scripty] Re: Mass AJAX Requests

2009-03-11 Thread T.J. Crowder
Hi, Fails how? Which part is failing? What is the error? Are you overlapping the requests, or sending them serially? What have you already looked into? How have you tried to isolate the problem? Etc. etc. etc. -- T.J. Crowder tj / crowder software / com Independent Software Engineer, consul

[Proto-Scripty] Re: Ajax.Autocompleter blanks out page when used in an Internet Explorer IE framed jsp

2009-03-11 Thread krishna
Hi David, Thanks for your prompt reply. I will download the latest scriptaculous that you suggested and modify it and try again! Until then, as I said in my post, I tried to modify the controls.js a lot by customizing it to be able to display 1) what fields I want to display in the auto-completi

[Proto-Scripty] Re: Mass AJAX Requests

2009-03-11 Thread Richard Quadling
2009/3/11 Akshit Soota : > > I'm trying to send mass number of emails via prototype JS AJAX. it > fails at a certain point for bulk mails. What do I do !! I call a PHP > Page !! > > Regards, > akshits > > > Send all the data to PHP and have it process all the data in 1 go, rather than hundreds of

[Proto-Scripty] Mass AJAX Requests

2009-03-11 Thread Akshit Soota
I'm trying to send mass number of emails via prototype JS AJAX. it fails at a certain point for bulk mails. What do I do !! I call a PHP Page !! Regards, akshits --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Proto

[Proto-Scripty] Re: Bring element to top onEnd (draggable)

2009-03-11 Thread david
Hi Tia, the onEnd callback is called before scriptaculous reactivate original CSS value. so that is normal :)) Open Firebug, and have the HTML 'test' element visible inside it to see change in thge z-index value, do this first test: move me !!! new Draggable('test',{onEnd:testFunction}

[Proto-Scripty] Re: Event.observe(window, 'load' & Ajax.Updater

2009-03-11 Thread david
Hi james, a) the answer is on doc page: http://www.prototypejs.org/api/ajax/updater it says that "The onComplete callback will get invoked after the update takes place.", so the external load file are already loaded and element updated b) you should have inside the response a script tag that co

[Proto-Scripty] Re: Event.observe(window, 'load' & Ajax.Updater

2009-03-11 Thread T.J. Crowder
Hi, Ajax.Updater doesn't load external script files referenced by the new content at all, which sort of answers your order-of-events question. ;-) This is documented, but only if you go digging: Ajax.Updater says it updates the target element via Element#update[1], which in turn says it will use

[Proto-Scripty] Re: Editing Multiple Fields Simultaneously with InPlaceEditor

2009-03-11 Thread david
Hi Darryl, I'm completelly agree with the solution of Walter. But I still try to do what you want wITH autocompleter. I made some tests and it results in: this is my test1 text this is my test2 text Edit Save

[Proto-Scripty] Event.observe(window, 'load' & Ajax.Updater

2009-03-11 Thread James
so normally you can use Event.observe(window, 'load' to fire some js after loading, secure in the knowledge that all external js files have been loaded and all elements have been set up. Whats the equivalent for firing an event after an new Ajax.Updater('modal-ajaxdiv', url, { evalScripts:true })

[Proto-Scripty] Re: Download page via prototype. with making all scripts on page. Help with code.

2009-03-11 Thread david
Hi kevin, I'm sorry, I'm not sure to understand. you want to make an Ajax call to retrieve the complete list of script which already are in script tag. With the response, use it to update the placeholdeer div, and browser should load script. Am I right? btw, the initialisation of the Ajax.upda

[Proto-Scripty] Re: Ajax.Autocompleter blanks out page when used in an Internet Explorer IE framed jsp

2009-03-11 Thread david
Hi again krishna, try downloading the latest version of scriptaculous at: http://script.aculo.us/dist/scriptaculous-js-1.8.2.zip that could be another rerason. -- david On 11 mar, 12:08, david wrote: > Hi krishna, > > Is there a possibility to test a live exemple, because the problem > with a

[Proto-Scripty] Re: Ajax.Autocompleter blanks out page when used in an Internet Explorer IE framed jsp

2009-03-11 Thread david
Hi krishna, Is there a possibility to test a live exemple, because the problem with autocompleter is that it need ajax call. btw, I look at you're code, and see some strange initialisation of the autocomplter: your initialisation is new Ajax.Autocompleter('nameId', 'nameChoicesDivId', '/someActi

[Proto-Scripty] Re: How to correct the following code?

2009-03-11 Thread ColinFine
On Mar 10, 3:49 pm, SamuelXiao wrote: > Hi, ColinFine, in my javascript code.  The prev.js is to do links with > URL preview.  It is expected to show a preview box with linked > content.  However, in my testing, prev.js can work on its own, when it > comes to using both script01.js and prev.js

[Proto-Scripty] Re: Bring element to top onEnd (draggable)

2009-03-11 Thread ColinFine
On Mar 10, 12:15 pm, Wouter Immerzeel wrote: > hey hi > > I have an element which I wat to be on top (zIndex) after drag. > > but if I try f.i > > new Draggable(mydiv,{onEnd: function() { >                                         $(mydiv).addClassName('whatever'); >                        

[Proto-Scripty] Re: Proposal for improving bind() + adding "unbind()" support

2009-03-11 Thread T.J. Crowder
> That has me thinking. Do the closures really consume as much additional > memory as the entire host scope's execution context, plus it's own, or just > the added pointers to the variables it actually closes over (i.e. uses > within it). According to the spec, every execution context has a "vari

[Proto-Scripty] Ajax.Autocompleter blanks out page when used in an Internet Explorer IE framed jsp

2009-03-11 Thread krishna
My autocompleter blanks the whole frame whenever I start typing in my textbox in my jsp page loaded in a frame whereas it is supposed to load my div with the available options. This is my first piece of nice code (autocompleter) written using Prototype 1.6.0.3 downloaded from the prototype websit