- We design and build extraordinary applications for companies looking to make the next great idea a reality.
- learn more
Scriptaculous: Fixing Hover After Highlight
One of the annoying things about the highlight visual effect in Scriptaculous is that it will break your :hover background-color CSS definitions. The occurs because scriptaculous sets the background-color style property of the element to whatever it was set to before the effect began. This behavior would be desirable if you're using inline styles or setting the style property through javascript, but you will run into issues if you're doing it The Right Way™ and using CSS classes and Element.add/removeClassName. Fortunately, there is an easy solution to this problem.
Topics: Scriptaculous
Multiple Column Sorting with Drag and Drop using Scriptaculous
The other day I wanted to do drag and drop between multiple columns using scriptaculous. Allowing this behavior is extremely simple, but out of the box the interaction feels clunky. Here, we'll be going through an example of how to do multi-column drag and drop with scriptaculous.
Enabling multi-column drag and drop just involves setting a single option, but without setting a few other options the dragging will feel jittery and won't allow us to drop on empty areas. Also, interaction with the server will require a small bit of consideration to support persistence of any changes.
Topics: Javascript, Ruby on Rails, Scriptaculous
JRails: Scriptaculous on top of JQuery
Prototype and Scriptaculous had their origins in Ruby on Rails before spinning off. There they went head to head with the lighter, leaner JQuery. Now the circle is complete, with Scriptaculous functionality on top of JQuery making its way back into RoR in the form of JRails.
jRails is a drop-in jQuery replacement for Prototype/script.aculo.us on Rails. Using jRails, you can get all of the same default Rails helpers for javascript functionality using the lighter jQuery library.
This is certainly good news for folks who do a fair bit of mashing up. Combining two sites or services, one of which uses Prototype and the other JQuery, can be a bit painful.
Technorati Tags: ajax, prototype, scriptaculous, jquery, ruby on rails
Topics: Ajax Frameworks, jQuery, Ruby on Rails, Scriptaculous
Why Does Scriptaculous Need Prototype?
I've been going through the Scriptaculous effects library in some detail. After grokking all there is to know about effects queues, I was left with one question: why does the effects library have a dependency on Prototype? The dependency could be removed with maybe two dozen lines of Javascript. So, why the dependency?
After having several other frameworks arm wrestle me for the $ identifier, I'd like to drop Prototype at the nearest corner.
Anyhow, I'm working on something involving Scriptaculous now that will likely make me the but of both jokes and death threats. Stay tuned.
Topics: Ajax Frameworks, Prototype, Scriptaculous
About Pathfinder
Recent
- Bandwidth profiling Flex projects and more with Charles
- iPhone SDK: UIViewController Testing & TDD
- Icons are evil; so are menus - unless you do them right
- The Truth About Designing For Security
- GWT, Gadgets and OpenSocial, Part 2
- Has Many has_many: A Refactoring Story
- The Hidden Power of Canvas
- Review of fixture_replacement2 plugin
- Chess Game Viewer in GWT
- From JSP to Ruby on Rails: First thoughts on front-end coding conventions
Archives
- November 2008
- October 2008
- September 2008
- August 2008
- July 2008
- June 2008
- May 2008
- April 2008
- March 2008
- February 2008
- January 2008
- December 2007
- November 2007
- October 2007
- September 2007
- August 2007
- July 2007
- June 2007
- May 2007
- April 2007
- March 2007
- February 2007
- January 2007
- December 2006
- November 2006
- October 2006
- September 2006
- August 2006
- July 2006
- June 2006
- May 2006
- April 2006
- March 2006


