Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Fixed #874
  • Loading branch information
jzaefferer committed Jan 31, 2007
1 parent a82b048 commit d4849a0
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
3 changes: 3 additions & 0 deletions src/jquery/coreTest.js
Expand Up @@ -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() {
Expand Down
2 changes: 1 addition & 1 deletion src/jquery/jquery.js
Expand Up @@ -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] ] );

Expand Down

0 comments on commit d4849a0

Please sign in to comment.