From c7d1737d47c1846beee5d145dd73dd7924a6eea9 Mon Sep 17 00:00:00 2001 From: Brice Maron Date: Tue, 1 Nov 2011 22:35:13 +0100 Subject: attempt to manage some special chars in file list Added a jquery function to filter by attributes. Add more logging in rename file Use the new function to avoid errors --- core/js/js.js | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'core/js') diff --git a/core/js/js.js b/core/js/js.js index 9e814ca0729..440f504c8f7 100644 --- a/core/js/js.js +++ b/core/js/js.js @@ -401,3 +401,10 @@ if (!Array.prototype.map){ return res; }; } + +/** + * Filter Jquery selector by attribute value + **/ +$.fn.filterAttr = function(attr_name, attr_value) { + return this.filter(function() { return $(this).attr(attr_name) === attr_value; }); +}; -- cgit v1.2.3