[Proto-Scripty] Re: Drag / Drop with TinyMCE

2008-09-18 Thread bluezehn
I haven't come across this before, but as a guess somehow TinyMCE's event listeners are being detached from the textarea. Try re-invoking TinyMCE's event listening function whenever that LI is dropped maybe? On Sep 17, 8:27 pm, dante2010 [EMAIL PROTECTED] wrote: Hi, I am using TinyMCE as my

[Proto-Scripty] Re: JSON for Novice

2008-09-18 Thread T.J. Crowder
Now in prototype, it does automatically decode this for you. I can't remember off the top of my head where it goes! The Ajax.Response object[1] passed to the handlers has a responseJSON property, so if your server-side page returns this JSON: { success: true, message:

[Proto-Scripty] Re: JSON for Novice

2008-09-18 Thread bluezehn
There ya go - knew prototype did that somewhere! Cheers for filling in the gaps T.J. On Sep 18, 11:02 am, T.J. Crowder [EMAIL PROTECTED] wrote: Now in prototype, it does automatically decode this for you. I can't remember off the top of my head where it goes! The Ajax.Response object[1]

[Proto-Scripty] Re: delegating the event on document

2008-09-18 Thread david
Hi Rauan, A question, does the focus effect bubble ?? because this work: $(document.body).observe('click', function(e) { var _elem=Event.element(e); alert(_elem.tagName); return; }); but not the same code when you use the focus event instead of the click event works. -- david On 18

[Proto-Scripty] Re: delegating the event on document

2008-09-18 Thread Rauan Maemirov
Hmm, it's strange. Because your code works fine. But, if I change it to $(document.body).observe('focus', function(e) { var _elem=Event.element(e); alert(_elem.tagName); return; }); it doesn't work. On Sep 18, 5:43 pm, david [EMAIL PROTECTED] wrote: Hi Rauan, A question, does the

[Proto-Scripty] Re: Autocompleter with multiple word input?

2008-09-18 Thread Walter Lee Davis
Naturally, I found it in the source as soon as I asked in public. // Tokenized incremental autocompletion is enabled automatically // when an autocompleter is instantiated with the 'tokens' option // in the options parameter, e.g.: // new Ajax.Autocompleter('id','upd', '/url/', { tokens: ',' });

[Proto-Scripty] Re: how can we make XHR (AJAX ) calls to other domain ?

2008-09-18 Thread Rama
Thanks for the community i have resolved my problem . I have used iframes and implemented the cross domain communication using fragment identifiers. i opted for iframe as it makes my task easier. much more details are given in below links

[Proto-Scripty] Re: Showing display:none content fails

2008-09-18 Thread bluezehn
You should set style=display:none; in the actual html rather than the css for it to be compatible with prototype. Your code at the bottom is very confusing at the moment as well. It's saying, toggle-fade the box and grow it (at the same time). I'd just go for Element#hide(), Effect.Grow().

[Proto-Scripty] Re: Showing display:none content fails

2008-09-18 Thread Matt
Thanks for the speedy reply! I'm using Firebug actually, it's invaluable for this kind of thing, but I didn't know about the log/console function - thanks. I tried out your code like so: // hide other boxes $$('.box').each(function(node) { if(!node.id == newBox)

[Proto-Scripty] Re: Showing display:none content fails

2008-09-18 Thread bluezehn
Well I think it may be this: if(!node.id == newBox) which should be this: if(node.id != newBox) other wise use console.log debugs to sort out whether or not the .each() loop is firing for every element, if it's passing the above if conditional etc. Essentially work out which line is wrong by

[Proto-Scripty] Re: Showing display:none content fails

2008-09-18 Thread Matt
That was it - I should have spotted it, sorry. Thank you so much, this has really pulled me out of a rut! Matt On Sep 18, 2:46 pm, bluezehn [EMAIL PROTECTED] wrote: Well I think it may be this: if(!node.id == newBox) which should be this: if(node.id != newBox) other wise use

[Proto-Scripty] Re: 24 new messages in 10 topics - digest

2008-09-18 Thread Hugh Bothwell
Second attempt: I'm fairly new to Scriptaculous and trying to figure out how to do this properly: I have a menu of question-types and a Sortable list of questions. I want to be able to click on a menu-item (NOT a question) and have it generate a new question - already being dragged -

[Proto-Scripty] Re: delegating the event on document

2008-09-18 Thread Ken Snyder
david wrote: Hi Rauan, A question, does the focus effect bubble ?? because this work: $(document.body).observe('click', function(e) { var _elem=Event.element(e); alert(_elem.tagName); return; }); but not the same code when you use the focus event instead of the click event

[Proto-Scripty] Re: 24 new messages in 10 topics - digest

2008-09-18 Thread T.J. Crowder
Hugh, Two things: 1. Even if you aren't happy with responses to your questions, it's not okay to repost. Your original post did show up. In fact, you got a reply in that thread before you reposted and started this second thread. For readers of this thread, here's his original and if you feel

[Proto-Scripty] Re: issues with getElementBySelector

2008-09-18 Thread Justin Perkins
On Thu, Sep 18, 2008 at 10:09 AM, Matt Foster [EMAIL PROTECTED] wrote: bluezehn, the $$ method just executes getElementsBySelector on the document. http://prototypejs.org/api/element/getelementsbyselector Doesn't $$ use Element#select? Nobody should be using getElementsBySelector if you're

[Proto-Scripty] Move a sortable with javascript

2008-09-18 Thread fintch2309
Is there any way to move sortable items around using javascript? I want to be able to move an item from one sortable to another on the page load. Any help or ideas would be great! Thanks, Fintch --~--~-~--~~~---~--~~ You received this message because you are

[Proto-Scripty] order of operations

2008-09-18 Thread BrentNicholas
I was going to ask another question, but in tying it out I realised there is a more fundamental question here.. Q: within a function, do the statements run in order? if one statement is running will it move on to the next? I faintly recall reading something about js not paying attention to

[Proto-Scripty] Re: order of operations

2008-09-18 Thread BrentNicholas
Maybe I should check up on my old posts... Matt answered it quite well here... http://groups.google.com/group/prototype-scriptaculous/browse_thread/thread/ffd60dfc2a95899a?hl=en Thanks Matt! On Sep 18, 10:23 am, BrentNicholas [EMAIL PROTECTED] wrote: I was going to ask another question, but

[Proto-Scripty] Re: multipart/form-data and prototype

2008-09-18 Thread BrentNicholas
Matt, Thanks! This answered another post I had before checking up on this one... Thanks again! BN On Sep 18, 8:19 am, Matt Foster [EMAIL PROTECTED] wrote: Using an iframe to upload a file isn't too difficult and can be done with almost any server side language, you simply post the form to

[Proto-Scripty] Re: order of operations

2008-09-18 Thread david
Hi Nicholas, the problem you mention is I think not a JS problem, because all instruction runs in order. The problem is more a network one. What I mean is when you submit the form, I understand that just after you send the AJAX request to see if everything is well done. The problem here is that

[Proto-Scripty] Re: Move a sortable with javascript

2008-09-18 Thread david
Hi fintch2309, go and have a look to the scriptaculous doc for sortable. It begin with: A Sortable is a quick way to initialize many Draggable elements in a container element. When you create a new Sortable, it takes care of the creation of the corresponding draggable Droppables. the reference

[Proto-Scripty] Re: 7 new messages in 7 topics - digest

2008-09-18 Thread david
Hi Hugh, I think TJ is right , because I have an answer for you :(( If it is not what you attempt, then post a reply to explain what you want and we can go forward step by step !! For your problem, if you have a *LIVE* exemple that could probably help, because the code you give us is a template

[Proto-Scripty] Re: AJAX autocompleter

2008-09-18 Thread Justin Perkins
On Thu, Sep 18, 2008 at 2:30 PM, Jack D [EMAIL PROTECTED] wrote: Hello, any clue regarding memory leak? What version of IE? IE is well known for it's memory leaks with JavaScript. I recommend using a memory leak tool for IE rather than just looking at the task manager. sIEve is one

[Proto-Scripty] Re: AJAX autocompleter

2008-09-18 Thread Justin Perkins
On Thu, Sep 18, 2008 at 3:02 PM, Jack D [EMAIL PROTECTED] wrote: Hi Justin, I'm using IE 6. In the memory leak tool which you've specified, if the #leak is showing some number, then does it mean that its a memory leak? I guess, but with IE there will be all sorts of stuff marked as #leak.

[Proto-Scripty] Re: AJAX autocompleter

2008-09-18 Thread Jack D
Hi Justin, I'm using IE 6. In the memory leak tool which you've specified, if the #leak is showing some number, then does it mean that its a memory leak? Thanks! On Thu, Sep 18, 2008 at 12:39 PM, Justin Perkins [EMAIL PROTECTED]wrote: On Thu, Sep 18, 2008 at 2:30 PM, Jack D [EMAIL

[Proto-Scripty] Re: issues with getElementBySelector

2008-09-18 Thread banry
Sorry for this, i've found the error the variable l is used in both the for loop for elements and later down in the code. On Sep 18, 4:56 pm, kangax [EMAIL PROTECTED] wrote: banry wrote: I'm trying to convert some code from mootools to prototype, but I can get the first ul to work but none

[Proto-Scripty] Re: Draggables needs remove (like Droppables)

2008-09-18 Thread bluezehn
From API: Called whenever a Draggable is released over the Droppable and the Droppable is accepts it. The callback gets three parameters: the Draggable element, the Droppable element and the Event. You can extract additional information about the drop – like if the Ctrl or Shift keys were pressed