Commit f7ae9a5c f7ae9a5c9b6238b80de938f3325c7011998eadf1 by Nicolas Perriault

refs #35 - backport of ded62ff4: Use ClientUtils.findOne instead of document.quer…

…ySelector in the Casper.fill method
1 parent 8999c3b0
...@@ -478,7 +478,7 @@ Casper.prototype = { ...@@ -478,7 +478,7 @@ Casper.prototype = {
478 // Form submission? 478 // Form submission?
479 if (submit) { 479 if (submit) {
480 this.evaluate(function(selector) { 480 this.evaluate(function(selector) {
481 var form = document.querySelector(selector); 481 var form = __utils__.findOne(selector);
482 var method = form.getAttribute('method').toUpperCase() || "GET"; 482 var method = form.getAttribute('method').toUpperCase() || "GET";
483 var action = form.getAttribute('action') || "unknown"; 483 var action = form.getAttribute('action') || "unknown";
484 __utils__.log('submitting form to ' + action + ', HTTP ' + method, 'info'); 484 __utils__.log('submitting form to ' + action + ', HTTP ' + method, 'info');
......