- Make the auto-linebreak filter also ignore the contents of <script>.
This makes it easier to use JavaScript (e.g. Google Adsense) inside blocks.4.7.x
parent
755da4bc0e
commit
b42e2b6760
|
@ -956,7 +956,7 @@ function _filter_autop($text) {
|
|||
if ($i % 2) {
|
||||
// Opening or closing tag?
|
||||
$open = ($chunk{1} != '/');
|
||||
list(, $tag) = split('[< ]', $chunk);
|
||||
list($tag) = split('[ >]', substr($chunk, 2 - $open), 2);
|
||||
if (!$ignore) {
|
||||
if ($open) {
|
||||
$ignore = true;
|
||||
|
|
|
@ -956,7 +956,7 @@ function _filter_autop($text) {
|
|||
if ($i % 2) {
|
||||
// Opening or closing tag?
|
||||
$open = ($chunk{1} != '/');
|
||||
list(, $tag) = split('[< ]', $chunk);
|
||||
list($tag) = split('[ >]', substr($chunk, 2 - $open), 2);
|
||||
if (!$ignore) {
|
||||
if ($open) {
|
||||
$ignore = true;
|
||||
|
|
Loading…
Reference in New Issue