473,834 Members | 1,908 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Script.aculo.us Sortable lists, multiple containment, with limits.

Daz
Hi guys,

I'm trying to make a script.aculo.us sortable list have a limited
number of elements in it. Now I can check for this really easily and
have a warning message, and of course the php throws an error back
anyway so they can't actually save more than the limit, but, is there
a way I can stop them from dropping the damn thing in the list if it's
full?

I thought about dynamically setting the containment array, so that
only the lists with space were on there, but script.aculo.us does not
seem to want to take a variable instead of the array.

So my next thought was to check onChange whether the item could be
dropped and get it to revert swoosh back over to it's starting point.
But i'm not too sure on how to do this. Any help would be much
appreciated!

Thanks!
Darren.
Jan 12 '08 #1
12 5476
Daz wrote:
I'm trying to make a script.aculo.us sortable list [...]
My sincere condolences.
PointedEars
--
Use any version of Microsoft Frontpage to create your site.
(This won't prevent people from viewing your source, but no one
will want to steal it.)
-- from <http://www.vortex-webdesign.com/help/hidesource.htm>
Jan 12 '08 #2
Daz
Thanks for that really constructive comment. If you have a better idea
I'd love to hear it.
Jan 13 '08 #3
On Jan 13, 9:12*am, Daz <uphanleyd...@g mail.comwrote:
Hi guys,

I'm trying to make a script.aculo.us sortable list...
Ask in a group that's interested in the scriptaculous.j s library, this
group isn't.

<URL: http://groups.google.com.au/group/ru...s?hl=en&lnk=li
>

--
Rob

Jan 13 '08 #4
On Jan 13, 6:32*am, Daz <uphanleyd...@g mail.comwrote:
Thanks for that really constructive comment. If you have a better idea
I'd love to hear it.
Please quote what you are replying to.

As for your original question. It is a waste of time to build
anything on top of Prototype. Scriptaculous (sp?) is built on
Prototype and so was a waste of time for its developers. It doesn't
make sense to waste your time building on top of their mistake.
Realize that this sort of junk code works only in a handful of modern
browsers and is constantly twiddled with to keep up with revised
versions. The same goes for jQuery, Dojo, YUI, etc.

If you feel you really want to build a bloated, unreliable and
inaccessible site, then post your question to a group that deals with
Prototype/Scriptaculous (those groups are full of people with similar
aspirations.) Otherwise, learn JavaScript.
Jan 13 '08 #5
VK
On Jan 13, 3:44 pm, David Mark <dmark.cins...@ gmail.comwrote:
If you feel you really want to build a bloated, unreliable and
inaccessible site, then post your question to a group that deals with
Prototype/Scriptaculous (those groups are full of people with similar
aspirations.) Otherwise, learn JavaScript.
Such response assumes that you have a much better alternative to
something like:
http://wiki.script.aculo.us/scriptac...tableListsDemo
in this case you missed to post a code or a URL in your response.

Other regular c.l.j. alternatives if I remember them properly:

1. Don't use any libraries, do anything every time from the scratch.
1-1. If you don't know Javascript good enough then you are busted
because there is not descent online sources to learn it.
1-2. If you don't have time to reinvent the wheel and test it in
different environment then you are an idiot who's wasting everyone's
time here.
1-3. If you have enough time, money and silliness for doing 1-2 then
your solution still will be a sucky suck because no one knows how to
write Javascript properly except a very few of us.
1-4. If you hope to improve your knowledge before doing 1-2 then see
1-1.

2. Javascript can be disabled and even if enabled you are not
guaranteed that you script will work as intended on absolutely all
browsers with script support: ergo Javascript programming is futile by
its very nature.

3. If ones wondering what a hey people - who are giving all these
valuable advises as above - are doing at comp.lang.javas cript: this
question alas will remain unanswered because it is a dark mystery for
themselves.

To OP:
Scriptaculous is not a form data validator, it is a complex library.
Most readers here do not have enough of knowledge to properly analyze
its low level structure to answer questions like yours; and a very few
who have - they do not have enough of spare time to do so. Some others
simply refuse to study Scriptaculous because they do not agree with
any coding style other than theirs. So rather than being moved by
points 1, 2, 3 above I would suggest to repost your question at
http://groups.google.com/group/rubyonrails-spinoffs
"Talk about script.aculo.us and Prototype as they fit inside of Rails
and outside."

P.S. Sortable objects expose onChange and onUpdate event handlers so
thoretically one can attach a custom limit check to one of them. Still
a better internal solution can be found.
Jan 13 '08 #6
On Jan 13, 10:02*am, VK <schools_r...@y ahoo.comwrote:
On Jan 13, 3:44 pm, David Mark <dmark.cins...@ gmail.comwrote:
If you feel you really want to build a bloated, unreliable and
inaccessible site, then post your question to a group that deals with
Prototype/Scriptaculous (those groups are full of people with similar
aspirations.) *Otherwise, learn JavaScript.

Such response assumes that you have a much better alternative to
something like:http://wiki.script.aculo.us/scriptac...tableListsDemo
I certainly do.
in this case you missed to post a code or a URL in your response.
I missed nothing.
>
Other regular c.l.j. alternatives if I remember them properly:

1. Don't use any libraries, do anything every time from the scratch.
Nobody does everything every time from scratch.
*1-1. If you don't know Javascript good enough then you are busted
because there is not descent online sources to learn it.
Sure there are. This group is one (as long as people skip your
posts.)
*1-2. If you don't have time to reinvent the wheel and test it in
different environment then you are an idiot who's wasting everyone's
time here.
I think it is very clear who the idiot is.
*1-3. If you have enough time, money and silliness for doing 1-2 then
your solution still will be a sucky suck because no one knows how to
write Javascript properly except a very few of us.
Certainly you are not included in that group.
*1-4. If you hope to improve your knowledge before doing 1-2 then see
1-1.

2. Javascript can be disabled and even if enabled you are not
guaranteed that you script will work as intended on absolutely all
browsers with script support: ergo Javascript programming is futile by
its very nature.
Your posts are certainly futile.
>
3. If ones wondering what a hey people - who are giving all these
valuable advises as above - are doing at comp.lang.javas cript: this
question alas will remain unanswered because it is a dark mystery for
themselves.
The only mystery is what you are doing here. You've been told a 10000
times that your opinions are worthless.
>
To OP:
Scriptaculous is not a form data validator, it is a complex library.
It is a Prototype extension that adds special effects and drag and
drop.
Most readers here do not have enough of knowledge to properly analyze
its low level structure to answer questions like yours; and a very few
who have - they do not have enough of spare time to do so. Some others
simply refuse to study Scriptaculous because they do not agree with
any coding style other than theirs. So rather than being moved by
points 1, 2, 3 above I would suggest to repost your question athttp://groups.google.c om/group/rubyonrails-spinoffs
"Talk about script.aculo.us and Prototype as they fit inside of Rails
and outside."
Idiot. One only has to study Prototype to know Scriptaculous (sp?) is
worthless. You can't build anything stable on a swamp.
>
P.S. Sortable objects expose onChange and onUpdate event handlers so
What are "exposed event handlers?"
thoretically one can attach a custom limit check to one of them. Still
a better internal solution can be found.
Will you please stop posting here.
Jan 13 '08 #7
VK
On Jan 13, 9:47 pm, David Mark <dmark.cins...@ gmail.comwrote:
If you feel you really want to build a bloated, unreliable and
inaccessible site, then post your question to a group that deals with
Prototype/Scriptaculous (those groups are full of people with similar
aspirations.) Otherwise, learn JavaScript.
Such response assumes that you have a much better alternative to
something like:http://wiki.script.aculo.us/scriptac...tableListsDemo

I certainly do.
So you are ready to provide a link or post a code? Then why are you
keep wasting time and words? That is your 2nd post here so far and
still not a hint for an alternative solution. Try do not waste your
3rd and last attempt ;-)
Jan 13 '08 #8
On Jan 13, 1:56*pm, VK <schools_r...@y ahoo.comwrote:
On Jan 13, 9:47 pm, David Mark <dmark.cins...@ gmail.comwrote:
If you feel you really want to build a bloated, unreliable and
inaccessible site, then post your question to a group that deals with
Prototype/Scriptaculous (those groups are full of people with similar
aspirations.) *Otherwise, learn JavaScript.
Such response assumes that you have a much better alternative to
something like:http://wiki.script.aculo.us/scriptac...tableListsDemo
I certainly do.

So you are ready to provide a link or post a code? Then why are you
keep wasting time and words? That is your 2nd post here so far and
Sorry VK. You will have to learn JavaScript and write your own.
still not a hint for an alternative solution. Try do not waste your
3rd and last attempt ;-)
One available alternative solution for people who are clueless about
browser scripting (e.g. you) is to create designs that are within the
range of their abilities. Then they won't have to hitch their wagons
to fading stars like Prototype. It is interesting to note that the
"sortable" widget was clearly well beyond the range of the Prototype/
Scriptaculous authors as it is sn absolute dog (and infamously buggy.)

Or they can hire people who aren't so clueless. As you mentioned
money as a motivating factor for delegating complex scripting tasks to
million monkey armies, how much do you think it will cost to
constantly monitor and update a site that is based on the output of
such a group? How many customers will you lose each time their code
springs a leak and breaks your pages? Seems like it would be cheaper
to employ competent developers.
Jan 13 '08 #9
VK
On Jan 13, 11:52 pm, David Mark <dmark.cins...@ gmail.comwrote:
Sorry VK. You will have to learn JavaScript and write your own.
I cannot: it was recently proved that there is not a single descent
online source for that nor a single more-or-less big chunk of code to
learn over it.

Poor me... Poor others... But wait!
One available alternative solution for people who are clueless about
browser scripting (e.g. you) is to create designs that are within the
range of their abilities.
OK. If you are not blessed by David Mark yet then sit with ugly face
on a free template page from Google or Yahoo, don't try to pretend to
be anything near of someone who is as higher of you as the sky higher
of the earth.
Got it, thank you, Masta'.
Then they won't have to hitch their wagons
to fading stars like Prototype.
Of course, Masta'. Stupid usa' will never do dat again.
Let me run back to my Yahoo Free Page barn.
It is interesting to note that the
"sortable" widget was clearly well beyond the range of the Prototype/
Scriptaculous authors as it is sn absolute dog (and infamously buggy.)
It does work though: unlike your imaginary perfect solution that works
so far only in your proud head.
Or they can hire people who aren't so clueless. As you mentioned
money as a motivating factor for delegating complex scripting tasks to
million monkey armies, how much do you think it will cost to
constantly monitor and update a site that is based on the output of
such a group? How many customers will you lose each time their code
springs a leak and breaks your pages? Seems like it would be cheaper
to employ competent developers.
with David Mark in the head. Of course he did not provide a single
worthy line of code yet doing what the customer does need, but it is
enough to read how brave he is in criticizing anything on the market:
that alone suffices to get sure that you are investing into a right
man. Something just tells me that you have lost Daz as a potential
client even for a 10 bucks deal: normally a programmer on sell uses a
bit softer approach ;-)
Jan 13 '08 #10

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

22
23392
by: Matthew Louden | last post by:
I want to know why C# doesnt support multiple inheritance? But why we can inherit multiple interfaces instead? I know this is the rule, but I dont understand why. Can anyone give me some concrete examples?
2
2361
by: arjenmeijer | last post by:
I am using the Drag & Drop Sortable Lists with javaScript and CSS from http://tool-man.org/examples/sorting.html. It works beautifully in a single page, see http://www.molca.com/kkoke.html. However, if I load the page in a Iframe the list is not sortable. The javascript gets stuck, see http://www.molca.com/kknotoke.html. I have searched the complete Internet, but I can not find a reference to this particular problem. What is the basic idea...
2
1247
by: JAL | last post by:
Comments appreciated. I coded an approach to simulating multiple inheritance of implementation in C# using PIMPL and a type based static class factory that seems to combine the extensibility of inheritance with the encapsulation of containment. Hopefully, the C++/cli coders here can read this C# code. http://www.geocities.com/jeff_louie/oop27.htm
1
1958
by: Henri Schomäcker | last post by:
Hi folks, what I need is a kind of 2D-Array which should, in the end, represent a typical html-table and which should be sortable by column. I thought of an implementation, where an vector does not keep the rows, as usual, but holds the single _columns_ as lists. In this case, every column could have it's own datatype, just like database-tables and could be sortable by the list's sort function.
1
1565
by: vincemoon | last post by:
Sites such as download.com, dealtime.com, shopping.com, and tucows.com, feature impressive sortable lists of products. What software that imports CSV can be used to generate database-driven sortable product listings such as shown on such sites? I am already able to get CSV into sortable (by javascript) HTML tables that do not use databases, but there are problems with this such as the slow sort time when there are many items, the...
0
1020
by: jon.ronnenberg | last post by:
Hi all. Does any of you guys know of any AJAX .NET components that uses script.aculo.us (or prototype, lightbox or Rico for that matter)? Right now I'm leaning towards using Jayrock webservices and static HTML pages, if I want to use those cool js libraries. What is your approach?
6
2277
by: Toby Inkster | last post by:
Does anyone have any idea why this effect using script.aculo.us is working in Opera, but not Firefox? http://examples.tobyinkster.co.uk/Balloons2/Balloon%20tooltip.html (I've not had the courage to even try it in IE yet!) Any ideas for a fix? Thanks
1
2103
by: hedgehog | last post by:
I've always been a do-it-yourselfer when it comes to referencing DOM, doing lil animations and Ajax queries, etc, but I thought I'd give someone else's toolkit a spin. Aside from sorting out that jQuery's small and Script.aculo.us' home page animation doesn't always start in FF 2.0.0.3, I've no clue as to which toolkits are better suited to which tasks. Here's a general idea of the sorts of projects I'll be coding over the next year:
5
2279
by: empiresolutions | last post by:
Hello Fellow Developers, I am using the awesome drag and drop script found at http://script.aculo.us/. I have also added a modification that interacts to a db for reordering upon release of a dragable item. Within each dragable is a input checkbox. This checkbox holds a DB id value that is sent on submit. This process works fine in IE, but in FF the checkbox values dont get sent via GET, or POST. How do i get FF to react as i think it...
0
9646
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10512
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10550
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9332
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7760
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5627
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5796
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
3981
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
3083
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.