Skip to content

Commit

Permalink
Code style, fix too long line
Browse files Browse the repository at this point in the history
  • Loading branch information
ggppdk committed Dec 11, 2016
1 parent 5cb88b1 commit e6855d7
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion plugins/system/sef/sef.php
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,8 @@ public function onAfterRender()
// Replace all unknown protocols in CSS background image.
if (strpos($buffer, 'style=') !== false)
{
$regex = '#style=\s*([\'\"])(.*):\s*url\s*\(([\'\"]|\&\#0?3[4|9];)?(?!/|\&\#0?3[4|9];|' . $protocols . '|\#)([^\)\'\"]+)([\'\"]|\&\#0?3[4|9];)?\)#m';
$regex_url = '\s*url\s*\(([\'\"]|\&\#0?3[4|9];)?(?!/|\&\#0?3[4|9];|' . $protocols . '|\#)([^\)\'\"]+)([\'\"]|\&\#0?3[4|9];)?\)';
$regex = '#style=\s*([\'\"])(.*):' . $regex_url . '#m';
$buffer = preg_replace($regex, 'style=$1$2: url($3' . $base . '$4$5$6)', $buffer);
$this->checkBuffer($buffer);
}
Expand Down

0 comments on commit e6855d7

Please sign in to comment.