From 3d23dac2a4ed42b7082890767862e9161d010c85 Mon Sep 17 00:00:00 2001 From: yp1000 Date: Mon, 10 Mar 2014 14:46:20 +0800 Subject: [PATCH] add getElementsByName --- jquery.joyride-2.1.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/jquery.joyride-2.1.js b/jquery.joyride-2.1.js index 72fb38d..7ba048b 100755 --- a/jquery.joyride-2.1.js +++ b/jquery.joyride-2.1.js @@ -399,11 +399,14 @@ set_target : function () { var cl = settings.$li.attr('data-class'), id = settings.$li.attr('data-id'), + na = settings.$li.attr('data-name'), $sel = function () { if (id) { return $(settings.document.getElementById(id)); } else if (cl) { return $('.' + cl).filter(":visible").first(); + } else if (na) { + return $(settings.document.getElementsByName(na)); } else { return $('body'); }