Hi all,
I've just added d&d sorting to a list where each item is a link_to ..
Problem: when I drop an item to its new location, the browser think I
clicked, and follows the link.
Any idea?
TIA.
Alain
___
Rails-spinoffs mailing list
Rails-spinoffs@
On 2/9/06, Alain Ravet <[EMAIL PROTECTED]> wrote:
> Hi all,
>
> I've just added d&d sorting to a list where each item is a link_to ..
> Problem: when I drop an item to its new location, the browser think I
> clicked, and follows the link.
> Any idea?
Roll a 1d20 to make a saving throw vs. clicking
When a 'draggable' element is made 'sortable', it no longer follows the
mouse horizontally when you drag it.
Is there a solution/workaround?
TIA
Alain
___
Rails-spinoffs mailing list
Rails-spinoffs@lists.rubyonrails.org
http://lists.rubyonrails.org/
On 2/9/06, Deco Rior <[EMAIL PROTECTED]> wrote:
> If I want to stop observing a div Is this the format?
>
> Event.stopObserving($(''mydiv'),'click');
The stopObserving function expects you to pass the handler(/observer)
in as well. Both detechEvent (IE) and removeEventListener (W3C)
require it.
Yes, use the constraints
options of Sortable.create
Alain Ravet wrote:
When a
'draggable' element is made 'sortable', it no longer follows the mouse
horizontally when you drag it.
Is there a solution/workaround?
TIA
Alain
___
On 2/9/06, Jeremy Kitchen <[EMAIL PROTECTED]> wrote:
> as for this, I believe Event.observe handles finding the proper event object
> for you and passes that to your function. This is what I've experienced
> anyways :)
Event.observe() does nothing to smooth out passing the event in as a
parameter
On 2/9/06, Jerod Venema <[EMAIL PROTECTED]> wrote:
> And another reply-to-self...make that:
>
> Event.observe(el, 'click', (function(event) {
> Element.addClassName(Event.element(event), 'myClass');
> );
... and you're missing a ')', or I could argue that you have one '(' too many.
Todd
_
Am Donnerstag, 9. Februar 2006 23:56 schrieb Ryan Gahl:
> Hi all. I have some performance tips to share. I had been having
> problems with the overall performance of the drag/drop objects. This is
> due largely to the fact that my project really pushes the limits
> (potentially thousands of draggab
Maybe don't make anchor tags draggable? Or you could do something like
change the href to point to '#' and move the actual href into your
javascript, and only call it if they click without dragging. Still, I
think making a clickable item draggable is begging for problems.
> -Original Message
Todd,
I finally got it working, though IE is a lot slower than Safari, or
Firefox.
You can check out my code here,:
http://thinkof.net/projects/js/highlight/highlight.html
http://thinkof.net/projects/js/highlight/javascript/highlight.js
Or you can download the entire thing to
EUREKA! WOOO HOOO I finally got it... ! ! !Here is the old code: setMouseEvents: function(el) { Event.observe(el, 'mouseover', (function(event) { Element.addClassName(el, 'highlightHover'); } )); }Here's what I did (works IE 6, Firefox 1.5, Safari 2.0.3): setMouseEvents: function(el)
Hello Everyone,I am working on a control collection for _javascript_/Ajax.Net. I am stuck on the class inheritance aspects of the prototype library. If someone could point me to an example it would be a great help. I have looked through the
controls.js of the scriptaculous library and found someth
You’re missing a level of extension
in the 2nd object. It should be…
Object.extend(Object.extend(MyControls.EditableTextbox.prototype,
MyControls.TextBox.prototype),
{
…stuff here…
});
From:
[EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of John Osborn
Hi everyone,
On 2/8/06, Todd Ross <[EMAIL PROTECTED]> wrote:
> On 2/8/06, Deco Rior <[EMAIL PROTECTED]> wrote:
> > So the data is returned in an object that can be handled rather than use
> > strain response.text?
> >
> >
> > Is there a library that allows JSON data object manipulation ?
>
> The c
On 2/10/06, Kevin Old <[EMAIL PROTECTED]> wrote:
> I'm using prototype 1.4.0 final.
>
> Any help is greatly appreciated!
I'd be happy to look at a live website.
Todd
___
Rails-spinoffs mailing list
Rails-spinoffs@lists.rubyonrails.org
http://lists.rubyo
Todd Ross schrieb:
On 2/9/06, Sebastian Kurt <[EMAIL PROTECTED]> wrote:
Hi,
I'm using PHP to fill my parameterlist for Autocompleter.Local as
shown in the example
(http://wiki.script.aculo.us/scriptaculous/show/Autocompleter.Local).
new Autocompleter.Local('recipeNameAlternative', 'rezept_li
Your PHP-built list has quotes in it which is breaking the JS.
Try:
'\''.str_replace("'", "\\'", $rezept_vorgabe[$i]).'\''
Also you know you can loop through an array with
http://www.php.net/foreach ?
Prints:
foo
bar
baz
boo
You should use the JavaScript console in Firefox 1.5, it alerts
Ryan,Thank you for the quick response. I tried what you suggested and still no luck. I also found in scriptaculous.js another example of inheritance that might also work:Autocompleter.Local = Class.create();
Autocompleter.Local.prototype = Object.extend(new Autocompleter.Base(),{ ..stuff});But t
thanks, i will try as far as I can.
Robin Haswell schrieb:
Your PHP-built list has quotes in it which is breaking the JS.
Try:
'\''.str_replace("'", "\\'", $rezept_vorgabe[$i]).'\''
there are no ' in $rezept_vorgabe[$i]. i add the in the loop(PHP), see
for ($i=0;$i<$ende;$i++) {
On 2/10/06, Greg Militello <[EMAIL PROTECTED]> wrote:
> You will notice former code had the hardcoded string 'highlightHover', but
> the new code get the value of that class via the class options.
Yup. Looks good. An option that doesn't do anything doesn't sound
like a very good option. :)
> C
On 2/10/06, Sebastian Kurt <[EMAIL PROTECTED]> wrote:
> there are no ' in $rezept_vorgabe[$i]. i add the in the loop(PHP), see
> for ($i=0;$i<$ende;$i++) {
> echo "'".$region_vorgabe[$i]."'";
> }
You are mistaken.
'Costa Rica',
'Cote d'Ivoire',
'Daenemark'
d'Ivoir
On 2/10/06, John Osborn <[EMAIL PROTECTED]> wrote:
> Thank you for the quick response. I tried what you suggested and still no
> luck. I also found in scriptaculous.js another example of inheritance that
> might also work:
>
> Autocompleter.Local = Class.create();
> Autocompleter.Local.prototype =
If my suggestion did not work then my next
thought is that you are not actually defining “MyControls” first.
You can’t define MyControls.TextBox is
MyControls is not defined.
From:
[EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of John Osborn
Sent: Friday, February 1
Ryan: No I am defining that with a var -- besides I would get a differant error that blah.blah is not a contructorTodd: The skeleton code I am using to create the base class is in my first email.
On 2/10/06, Ryan Gahl <[EMAIL PROTECTED]> wrote:
If my suggestion did not work then my ne
Ok then, the other thing then is your
MyControls.TextBox doesn’t seem to have an “initialize” method. That might have
something to do with it. Try this, change “baseInitialize to initialize. Then
you will have instantiate your base class in your subclass’s initialize method to
inherit, like
On 2/10/06, John Osborn <[EMAIL PROTECTED]> wrote:
> Todd: The skeleton code I am using to create the base class is in my first
> email.
Sorry. I was expecting to see MyControls.Base.
http://www.brainsick.com/prototype/classinheritance.html
There were a couple changes. Like Ryan said, you need
On Friday 10 February 2006 13:38, Sebastian Kurt wrote:
> okay, i can. http://lekapidia.ml-its.de/formtest/test.php
'Cote d'Ivoire'
you need to escape that inner single quote. Again, I would recommend using
some sort of json module to handle this for you.
-Jeremy
--
Jeremy Kitchen ++ [EMAIL
I think that's a bit overkill. My fix should work fine for anything that
doesn't include newlines. If this were my application I'd dump the data
in a hidden or maybe as an xml string and parse it with the
built-in DOM parser. Much better parse something in XML than *shudder*
javascript. JS sho
Robin Haswell wrote:
> I think that's a bit overkill. My fix should work fine for anything that
> doesn't include newlines. If this were my application I'd dump the data
> in a hidden or maybe as an xml string and parse it with the
> built-in DOM parser. Much better parse something in XML than *
Thanks for all you help and quick replies. It is still not working but it must be a syntax error or something I will have to look at it later.Thanks.On 2/10/06,
Todd Ross <[EMAIL PROTECTED]> wrote:
On 2/10/06, John Osborn <[EMAIL PROTECTED]> wrote:> Todd: The skeleton code I am using to create the
Hm I may be mistaken. AFAIU JSON is a JS-compatible serialization form?
Do browsers have built-in JSON deserializers?
My the way, you'd be surprised at how efficient XML parsers are. In
Python, it's quicker to decode a list from XML than using the Pickle
module (which is equivalent to PHP seri
Robin Haswell wrote:
> Hm I may be mistaken. AFAIU JSON is a JS-compatible serialization form?
> Do browsers have built-in JSON deserializers?
Well, they'd have to if they have JS interpreters right?
--
Michael Peters
Developer
Plus Three, LP
___
Ra
Michael Peters wrote:
Robin Haswell wrote:
Hm I may be mistaken. AFAIU JSON is a JS-compatible serialization form?
Do browsers have built-in JSON deserializers?
Well, they'd have to if they have JS interpreters right?
Um no, I mean can you convert a JSON object into a memory construct
wi
No, but from I understand (don't use JSON myself), it translates
directly into Javascript objects when eval'ed.
var myObj = eval(myJSONstring);
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Robin
Haswell
Sent: Friday, February 10, 2006 5:02 PM
To: rails
Oh I see. How interesting.
Eval scares me heh. Well in which case you'd have to unit-test JSON vs
XML to see which would be quicker. I have a feeling it'd be close
though, and I know which one I'd pick if that was the case.
-Rob
Ryan Gahl wrote:
No, but from I understand (don't use JSON my
Hi,
I want to add the value of my Autocompletion field to an input-field
by clicking on a (submit-)Button/Link. Is there any function that
provides me easy help in scriptalous-JS?
It would be nice if there is a possibility to give the added value a "+"
or "-" so the input-field knows if it has
thanks to all of you! this sign was the seed of all evil.
move it into an JS-Array helped to solve it
var temp_rezept_array = new Array();
//Schleife
thx sebastian
Todd Ross schrieb:
On 2/10/06, Sebastian Kurt <[EMAIL PROTECTED]> wrote:
there are no ' in $rezept_vorgabe[$i]. i add the in th
On Friday 10 February 2006 14:52, Robin Haswell wrote:
> I think that's a bit overkill. My fix should work fine for anything that
> doesn't include newlines. If this were my application I'd dump the data
> in a hidden or maybe as an xml string and parse it with the
> built-in DOM parser. Much bett
There are a few mistakes in this but yeah that would solve it for the
meantime.
-Rob
Sebastian Kurt wrote:
thanks to all of you! this sign was the seed of all evil.
move it into an JS-Array helped to solve it
var temp_rezept_array = new Array();
//Schleife
thx sebastian
Todd Ross schrieb:
On Friday 10 February 2006 15:05, Robin Haswell wrote:
> Oh I see. How interesting. Eval scares me heh. Well in which case you'd
> have to unit-test JSON vs XML to see which would be quicker. I have a
> feeling it'd be close though, and I know which one I'd pick if that was
> the case.
no need to
Oh I see! Sorry. That seems, well, bloody interesting. I don't do
anything like this at the moment (all AJAX) but I will consider that for
the future. I do need a way to encapsulate a load of HTML inside a JS
string accurately. At the moment's I'm just doing search/replace
escaping of quotes an
On Friday 10 February 2006 15:58, Robin Haswell wrote:
> Oh I see! Sorry. That seems, well, bloody interesting. I don't do
> anything like this at the moment (all AJAX) but I will consider that for
> the future. I do need a way to encapsulate a load of HTML inside a JS
> string accurately. At the m
Nice. As I say, I don't have a need to pass anything other than
straight-up strings at the moment, but that certainly is worth remembering.
Cheers.
-Rob
Jeremy Kitchen wrote:
On Friday 10 February 2006 15:58, Robin Haswell wrote:
Oh I see! Sorry. That seems, well, bloody interesting. I don't
Robin Haswell wrote:
> Michael Peters wrote:
>
>>
>> Robin Haswell wrote:
>>
>>> Hm I may be mistaken. AFAIU JSON is a JS-compatible serialization form?
>>> Do browsers have built-in JSON deserializers?
>>
>>
>> Well, they'd have to if they have JS interpreters right?
>>
>
>
> Um no, I mean ca
On 2/9/06, smi <[EMAIL PROTECTED]> wrote:
> I am using the latest version of prototype.js from the SVN, including
> the wonderful $$ operator to loop through a number of elements with a
> certain classname. In Firefox everything works fine, no JS error, but in
> IE I get an error in the .each funct
Hi Todd,
On 2/10/06, Todd Ross <[EMAIL PROTECTED]> wrote:
> On 2/10/06, Kevin Old <[EMAIL PROTECTED]> wrote:
> > I'm using prototype 1.4.0 final.
> >
> > Any help is greatly appreciated!
>
> I'd be happy to look at a live website.
>
Here's the page: http://kold.homelinux.com/prototype/testajax2.h
On 2/10/06, Kevin Old <[EMAIL PROTECTED]> wrote:
> Here's the page: http://kold.homelinux.com/prototype/testajax2.html
I was hoping to be able to play with your X-JSON approach because that
seems to be what you wanted originally. The latest iteration works
for me in Firefox, and I'd imagine will
On 2/10/06, Todd Ross <[EMAIL PROTECTED]> wrote:
> On 2/10/06, Kevin Old <[EMAIL PROTECTED]> wrote:
> > Here's the page: http://kold.homelinux.com/prototype/testajax2.html
>
> I was hoping to be able to play with your X-JSON approach because that
> seems to be what you wanted originally. The lates
Another way to ask the question:
"How to make a list of links sortable?"
I read the doc and scratched my head, but I found nothing, not even
dandruff.
Alain
> I've just added d&d sorting to a list where each item is a link_to ..
> Problem: when I drop an item to its new location, the brow
On 2/10/06, Kevin Old <[EMAIL PROTECTED]> wrote:
> On 2/10/06, Todd Ross <[EMAIL PROTECTED]> wrote:
> > On 2/10/06, Kevin Old <[EMAIL PROTECTED]> wrote:
> > > Here's the page: http://kold.homelinux.com/prototype/testajax2.html
> >
> > I was hoping to be able to play with your X-JSON approach becaus
Just include the ( and ) parens in your X-JSON header string.
On 2/10/06, Kevin Old <[EMAIL PROTECTED]> wrote:
> On 2/10/06, Kevin Old <[EMAIL PROTECTED]> wrote:
> > On 2/10/06, Todd Ross <[EMAIL PROTECTED]> wrote:
> > > On 2/10/06, Kevin Old <[EMAIL PROTECTED]> wrote:
> > > > Here's the page: htt
As the title says, _sortable list_ doesn't like 'in_place_editor' very much.
Problem: when you click on an editable element, the field editor and the
2 buttons appears - good - , BUT they keep following the mouse - bad -,
and moving, while you're in edit mode.
Alain
___
52 matches
Mail list logo