This commit is contained in:
Jörn Zaefferer 2007-01-31 21:48:14 +00:00
parent a82b048db8
commit d4849a0d35
2 changed files with 4 additions and 1 deletions

View File

@ -14,6 +14,9 @@ test("Basic requirements", function() {
test("$()", function() {
var main = $("#main");
isSet( $("div p", main).get(), q("sndp", "en", "sap"), "Basic selector with jQuery object as context" );
// make sure this is handled
$('<p>\r\n</p>');
});
test("length", function() {

View File

@ -38,7 +38,7 @@ var jQuery = function(a,c) {
// Handle HTML strings
if ( typeof a == "string" ) {
// HANDLE: $(html) -> $(array)
var m = /^[^<]*(<(.|\n)+>)[^>]*$/.exec(a);
var m = /^[^<]*(<(.|\s)+>)[^>]*$/.exec(a);
if ( m )
a = jQuery.clean( [ m[1] ] );