Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 7fe431c

Browse files
author
Thomas Edwards
committed
fix - trim the output of the fully rendered php to ensure that DOCTYPE is on the first line (fixes laravel#2359)
1 parent ff7feea commit 7fe431c

2 files changed

Lines changed: 2 additions & 1 deletion

File tree

src/Illuminate/View/Engines/PhpEngine.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ protected function evaluatePath($__path, $__data)
4242
$this->handleViewException($e);
4343
}
4444

45-
return ob_get_clean();
45+
return ltrim(ob_get_clean());
4646
}
4747

4848
/**

tests/View/fixtures/basic.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
1+
12
Hello World

0 commit comments

Comments
 (0)