Notes on jQuery 1.0 Compatibility Plugin && Interface Elements
As I noted before, after some sleuthing, I discovered that there is a compatibility plugin (click here for source) which is designed to allow code written for jQuery 1.0 to run under jQuery 1.1. Mainly what it does is re-implement a number of deprecated functions. I'm interested in it because I would like to use several elements from the Interface Elements library.
So far so good! I've replaced the stock jquery.js with version 1.1.1, and I am including the compatibility script afterwards. Interface Elements perform fine, and I have only found (so far) one bug with Drupal core's javascripts.
Read moreDrag-and-drop testing: interface for jQuery
I could use some excellent JS eyes to look at the right way to implement Drag-and-Drop using jQuery/Interface.
I've released a version for the MySite module (in the current HEAD release). See http://drupal.org/node/101471#comment-203584 for what I don't like about my implementation. Three points to emphasize to this audience:
1) I'd prefer to have a universal library; not one that is specific to my module. So the jQuery module http://drupal.org/project/jquery seems the right path to me.
Read moreExperimental theme - lumen

This project started about 4 months ago. At first it was just to contribute a nice little theme but it changed into a source of learning and experimentation on what could be done with Drupals' theming layer.
The code is commented pretty well so I hope others can learn from what's been done. Some of the ideas that went into the theme will eventually end up in the handbook and a site will be dedicated to it also.
Read morejquery module--a place for jQuery plugins and extensions
As more of us start using jQuery, we're getting the same jQuery plugin included in two, three, or more modules. Personally I've included tabs, cookie, and history in the jstools package. I've now seen the form plugin in three different modules. As well as duplicating work and code, we get swollen pageloads that load multiple copies of the same file from different locations (one for each module). And, potentially, problems if two different modules use different versions of the same plugin, and one overwrites the other.
Read moreDrag and drop standards
(I posted this on the dev list, but I think this is it's proper home.)
Now that we have jQuery in Drupal, there are all sorts of drag-and-drop
interface possibilities.
Questions, too, by the look of http://drupal.org/search/node/drag+and+drop.
I've been working on one for my project, using the interface jQuery plug-in (http://drupal.org/node/101471),
and have a two simple questions:
1) Do we have any best-practice guidelines on using drag-and-drop?
2) Specifically, if the action requires saving the state change, should that
Read moreHandling user access and Ajax
How does one handle access control when doing Ajax requests? Take a completely hypothetical example: I have my Drupal install setup in a way where only authenticated users may attach comments. I also want to add comments using an Ajax call instead of a normal fom submission (I said this was hypothetical, not that it was practical).
How would I make this secure? The comments box is stripped automatically for anonymous users, but anyone who knows where the Ajax call submits to will be able to send along the usual arguments. How do I make sure it was a validated user who submitted?
I have read some general articles on security and Ajax.
Read moreAdvanced Poll November Update
It's been five weeks since the last update and a ton of progress has been made on Advanced Poll:
- Ported to Drupal 5.0 - all new development is occuring on the 5.0 branch
- Dynamically add or remove poll choices
- PostgreSQL support (additional testing needed)
- Start dates for polls
- Submit votes using Ajax
- List polls at /polls
- Cache voting results
- Add/remove individual users from Electoral List and a button to clear it entirely
- Allow votes to be reset
- Numerous bug fixes
Demo available at http://advpoll.ck37.com and additional discussion can go in the Advanced Poll working group. Please submit all bug reports and feature requests to the issue queue.
Read morejQuery brakes gmap.module
Hi folks.
I followed this advice http://groups.drupal.org/node/1008#comment-3690 and modified /misc/*.js files. Now I see gmap.module doesn't work after this modification. (the module works OK when I copy those files back). Well, I mean not the module itself, but google maps. They just don't appear :(
Can anybody help please?
Read morePrototype v. jQuery - One blogger's conclusions
Hi all,
Here are a few sketchy to interpret, yet interesting tests results benchmarking Prototype v. jQuery, by Claudio Cicali. The blogger's conclusions: Despite rumors on the internet, jQuery is not slower than Prototype.
ajaxian.com has a few more comments on these tests.
Read morebehaviors.module: docking JavaScript behaviors into Drupal
Now that we have jQuery in Core, there are new JavaScript enhancements for Drupal popping up everywhere. Most of these enhancements are pretty small. To add them to a page, it usually requires a module. But those modules don't do much more than just adding the JavaScript file with drupal_add_js - the whole module system with all of its callbacks and so on is just overkill for that problem.
On #drupal we have discussed the need for a module that gathers all those JavaScript enhancements in just one module. In the rest of the proposal, I will use the word "behavior" for a JavaScript enhancement file.
Read more



