Over the past few months I've been fielding an increasing number of support requests via Twitter (for Cycle, BlockUI, and Form plugins). In some ways it's a nice way to respond to simple questions but obviously it's not well-suited for more in-depth questions and responses. I generally direct people to this Google Group for anything non-trivial but I'm wondering what others think about leveraging Twitter for simple Q&A. Thoughts? Mike http://twitter.com/malsup
Anyone familiar with this plugin? The docs say that it supports colspans but it doesn't appear to do so. The script has a checkCellColSpan function defined but it is never invoked. I really need colspan support.
http://dev.jquery.com/ticket/3737 TypeError occurred at line 1017 when ret[i] referred to a script element (FF3.05). 1016 if ( jQuery.nodeName( ret[i], "script" ) ) { 1017 ret[i].parentNode.removeChild( ret[i] );
I've just uploaded a new version of the Cycle Plugin: http://malsup.com/jquery/cycle/ This new version adds some new transition effects, the ability to create custom transitions, and the ability to transition on a click event rather than a timeout. But the biggest change is an overhaul to how transitions are defined. Transitions are now defined using a plugin scheme. This means you can create your own transition definitions, plug them in to the Cycle Plugin, and then use them by name. This provides a lot of flexibility, and together with the custom transition support lets you create some pretty wacky stuff. The documentation provides lots of examples. Cheers! Mike
I've been working on consolidating and refactoring my media plugins. The result is a single plugin that handles virtually any media type. Supported Media Players: - Flash - Quicktime - Real Player - Silverlight - Windows Media Player - iframe Supported Media Formats: Any types supported by the above players, such as: Video: asf, avi, flv, mov, mpg, mpeg, mp4, qt, smil, swf, w Audio: aif, aac, au, gsm, mid, midi, mov, mp3, m4a, snd, rm Other: bmp, html, pdf, psd, qif, qtif, qti, tif, tiff, xaml Docs and demos can be found at: http://malsup.com/jquery/media/ Mike
I just posted a small plugin for creating unobtrusive Silverlight objects using the Silverlight 1.0 beta. You can find the source and some documentation here: http://malsup.com/jquery/ag/ Mike
In case anyone missed it, Google recently released an API for mashing feeds on the client. http://googleajaxsearchapi.blogspot.com/2007/04/announcing-google-ajax-feed-api.html It's really quite cool (and fast). Below is a short demo of how it works. To try it, replace [your key] with your Google API key. Mike <html> <head> <style type="text/css"> body { font-family: 'trebuchet ms'; color: #555; font-size: small; } div.feed { margin: 20px; padding: 20px; border: 1px dashed #ddd; background: #ffd } div.date { font-size: smaller; color: #aaa } h1.blog { font-size: large; padding: 5px; margin: 2px 0; text-align: center } h2.feed { font-size: medium; padding: 0; margin: 2px 0 } </style> <script type="text/javascript" src="../rel/jquery-1.1.2.js"></script> <script type="text/javascript" src="http://www.google.com/jsapi?key=[your key]"></script> <script type="text/javascript"> google.load("feeds", "1"); google.setOnLoadCallback(function() { var sites = [ 'http://jquery.com/blog/feed/', 'http://feeds.feedburner.com/JohnResig', 'http://bassistance.de/feed/', 'http://www.stilbuero.de/feed/atom/', 'http://www.learningjquery.com/feed/', 'http://www.reybango.com/rss.cfm', 'http://feeds.feedburner.com/WebDeveloperBlog' ]; jQuery.each(sites, function(j,site) { var feed = new google.feeds.Feed(site); feed.load(function(result) { if (!result.error) { var max = Math.min(result.feed.entries.length, 5); // 5 at most var f = $('<div class="feed"></div>').appendTo('body'); f.append('<h1 class="blog">'+result.feed.title+'</h1>'); for (var i = 0; i < max; i++) { var entry = result.feed.entries[i]; var title = entry.title; var snip = entry.contentSnippet; var link = entry.link; var date = entry.publishedDate; f.append('<h2 class="feed"><a href="'+link+'">'+title+'</a></h2>') .append('<div class="date">'+date+'</div>') .append('<div class="snip">'+snip+'</div> '); } } }); }); }); </script> </head> <body></body> </html>
I've added file upload support to the form plugin and I could use some help testing it out. If this feature interests you then go ahead and grab the beta plugin at: http://malsup.com/jquery/form/file/jquery.form.js File upload support is baked right into the plugin and there are no external dependencies. The plugin will automatically detect file input elements and use an iframe to submit the form if there are files to be uploaded. No extra coding or metadata is needed to take advantage of this new feature. In addition, even though an iframe is used instead of the XHR object, callbacks and global triggers still work as expected (so any code that you have in place to display activity indicators or blocking elements will still work). However, there are some challenges when using iframes in this manner. For one, it is quite difficult to determine if the submit operation succeeded or failed. The iframe becomes the target of the submit operation and so that is where the server response is written. The form plugin does its best to determine the data type (html, xml, etc), but the status is always 'success' unless an exception is caught during the type determination. (Note that dojo and YUI haven't figured out how to solve the status problem either.) I've prepared a sample page with several forms here: http://malsup.com/jquery/form/file/ If you use this page for testing *please* be kind to my server and only upload small files! I'd really prefer that you download the plugin and integrate it into your own test environment if possible. I've done some testing on FF, IE and Opera and the results are encouraging. I don't have access to Safari so I'm sure there are issues lurking for that platform. If you're interested in the code you can find it all tucked into the end of the ajaxSubmit method in a function called "fileUpload". Mike _______________________________________________ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/
I just posted a new version of BlockUI. I bumped the version to 1.0 just for fun. Changes: - Element blocking with messages; you can now have custom messages appear over blocked content when blocking a subset of the page. - Improved "settings" support; it is now much easier to override the default blocking styles, including the overlay itself. So for example, using a blue overlay instead of white is a one-liner. - improved Opera 8 support Examples and documentation can be found at: http://malsup.com/jquery/block/ The plugin is available at: http://dev.jquery.com/browser/trunk/plugins/blockUI/jquery.block.js?format=txt Mike _______________________________________________ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/
I've just rewritten my Taconite Plugin and added some pretty cool features. If you're not familiar with Taconite, it's an easy way to effect multiple client-side updates with the results of a single ajax call. With this latest version there is absolutely no code required to process command documents returned from the server. The plugin detects taconite responses and automatically processes them for you. Other changes: - Available commands now include almost everything in the jQuery API - Vastly improved logging/debug support - Fully extensible Full details and examples can be found at: http://www.malsup.com/jquery/taconite/ Mike PS: For anyone using my old xmlExec plugin, this is a drop-in replacement. _______________________________________________ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/
For anyone seeking information about how to manage forms with jQuery, I've just updated the Form Plugin example page at: http://malsup.com/jquery/form/ You can find a quick start guide, API docs, examples, a FAQ and more. Mike _______________________________________________ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/
The latest version of the form plugin has some new features that you may not be aware of. New Functions: resetForm, clearForm and clearInputs // invokes the form's native 'reset' method $('#myForm').resetForm(); // clears all (appropriate) fields in the form $('#myForm').clearForm(); // clears matched fields $('.myStuff').clearInputs(); New Options for ajaxSubmit and ajaxForm: resetForm, clearForm // resets form after successful server response $('#myForm').ajaxForm({ resetForm: true }); // clears form after successful server response $('#myForm').ajaxForm({ clearForm: true }); As always, the latest form plugin can be found at: http://jquery.com/dev/svn/trunk/plugins/form/form.js?format=txt Full documentation can be found in the source file. Mike _______________________________________________ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/
I've been trying to chase down a problem with one of my unit tests. The issue is that evalScripts is executing and appears to find a script tag where none exists. Looking further, it seems that 'find' never returns a jQuery object of size 0. For cases like the one I was testing, where no match exists, find returns a jQuery object like this: [undefined]. That is, it has a size of 1 but element 0 is undefined. Things work fine in 1.0.4, but in the current SVN code the following happens: // alerts 1 (should be 0) alert($('no-such-tag', this).length); // alerts 'undefined' alert($('no-such-tag', this)[0]); Mike _______________________________________________ Jquery-dev mailing list Jquery-dev@bassistance.de http://lists.bassistance.de/mailman/listinfo/jquery-dev
Anybody have the lite build working for plugins? When I include plugins in my lite build the javadocs are not stripped (but they are from core). The min and pack builds seem to work just fine. lite.js looks like it should work but it doesn't (for me). Mike _______________________________________________ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/
I just checked in some more changes to the form plugin. The methods were reworked to use the standard plugin style for specifying options. The signatures for ajaxSubmit and ajaxForm now take just a single argument which is an object literal. Here are the details from the docs: ----------------- The following options are supported: target: Identifies the element(s) in the page to be updated with the server response. This value may be specified as a jQuery selection string, a jQuery object, or a DOM element. default value: null url: URL to which the form data will be submitted. default value: value of form's 'action' attribute method: The method in which the form data should be submitted, 'GET' or 'POST'. default value: value of form's 'method' attribute (or 'GET' if none found) before: Callback method to be invoked before the form is submitted. default value: null after: Callback method to be invoked after the form has been successfully submitted. default value: null dataType: Expected dataType of the response. One of: null, 'xml', 'script', or 'json' default value: null semantic: Boolean flag indicating whether data must be submitted in semantic order default value: false ... The dataType option provides a means for specifying how the server response should be handled. This maps directly to the jQuery.httpData method so the following values are supported: 'xml': if dataType == 'xml' the server response is treated as XML and the 'after' callback method will be passed the responseXML value 'json': if dataType == 'json' the server response will be evaluated and passed to the 'after' callback 'script': if dataType == 'script' the server response is evaluated in the global context ----------------- I've updated the example page and unit tests to reflect these updates: http://malsup.com/jquery/form/ Note: Like the previous update, this version of form.js requires jQuery 1.02 or later. Cheers. Mike _______________________________________________ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/
I've updated the form plugin once again to fix a bug in ajaxSubmit which I found while unit testing. I thought I'd take this opportunity to summarize the changes made recently: 1. Incorporated Matt Grimm's optimized serialization code. 2. Defaulted the form method to 'GET' per Klaus's suggestion. 3. Fixed ticket #160 using suggestions from Renato and Jörn. 4. Fixed bug in ajaxSubmit which caused inconsistent callback args in post-callback method. 5. Fixed bug in image submit element coordinates (requires dimensions plugin) 6. Updated documentation in the source file. I think (hope) everyone is on-board with the changes listed above. I'm also suggesting two other changes: 1. Rename form plugin's current "serialize" method to "formToArray" 2. Create a new "serialize" method in the plugin which returns the '&' delimited string. These last two items may cause issues for some but to me they are far more intuitive than what we currently have and I think the discussions earlier this week were leading in this direction. Currently, the form plugin's "serialize" method returns an array of objects and core's "serialize" method returns a '&' delimited string. On a final note, I've updated the demo page to include a link to run the unit tests. If some of you Safari users could run the unit tests I would appreciate it. Demo page: http://malsup.com/jquery/form/ Unit test: http://malsup.com/jquery/form/test.html Mike _______________________________________________ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/
In the attr method the following barfs: var fix = { ... cssFloat: fix["float"], ... }; _______________________________________________ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/