Created
June 15, 2009 21:41
-
-
Save will/130364 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env jruby | |
require 'rubygems' | |
require 'celerity' | |
url = "http://uiuc.us/jquery.html" | |
puts "url should be #{url}" | |
[:firefox, :internet_explorer].each do |browser| | |
b = Celerity::Browser.new :log_level => :severe, :browser => browser | |
b.goto url | |
b.buttons.first.click | |
puts "#{browser} got: #{b.url}" | |
end | |
# output | |
# url should be http://uiuc.us/jquery.html | |
# firefox got: http://www.google.com/ | |
# internet_explorer got: http://uiuc.us/jquery.html |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<head> | |
<meta http-equiv="Content-type" content="text/html; charset=utf-8"> | |
<title>jquery-bug</title> | |
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js" type="text/javascript" charset="utf-8"></script> | |
<script type="text/javascript" charset="utf-8"> | |
$(document).ready( function() { | |
$("form").submit(function(event){ | |
event.preventDefault(); | |
return false; | |
}); | |
}); | |
</script> | |
</head> | |
<body> | |
<form action="http://google.com"> | |
<input type=submit id="submit" /> | |
</form> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment