Commit 6ba13c1f by 汪伟伟

ini_set('pcre.backtrack_limit', '2097152');

parent d5010858
......@@ -342,6 +342,7 @@ class AlreadyDoneTaskController extends AdminController
$form->saved(function (Form $form) {
$start = 'src="';
$end = '" alt';
ini_set('pcre.backtrack_limit', '2097152');
$pattern = '/' . preg_quote($start) . '(.*?)' . preg_quote($end) . '/';
preg_match_all($pattern, $form->input('collects.net_img'), $matches);
$images = '';
......
......@@ -366,9 +366,9 @@ class NoDoneTaskController extends AdminController
// });
//保存后回调
$form->saved(function (Form $form) {
$start = 'src="';
$end = '" alt';
ini_set('pcre.backtrack_limit', '2097152');
$pattern = '/' . preg_quote($start) . '(.*?)' . preg_quote($end) . '/';
preg_match_all($pattern, $form->input('collects.net_img'), $matches);
$images = '';
......
......@@ -239,6 +239,7 @@ class TasController extends AdminController
$start = 'src="';
$end = '" alt';
$pattern = '/' . preg_quote($start) . '(.*?)' . preg_quote($end) . '/';
ini_set('pcre.backtrack_limit', '2097152');
preg_match_all($pattern, $form->input('guide'), $matches);
$images = '';
foreach ($matches[1] as $v) {
......@@ -304,6 +305,7 @@ class TasController extends AdminController
$start = 'src="';
$end = '" alt';
$pattern = '/' . preg_quote($start) . '(.*?)' . preg_quote($end) . '/';
ini_set('pcre.backtrack_limit', '2097152');
preg_match_all($pattern, $param['guide'], $matches);
$images = '';
foreach ($matches[1] as $v) {
......
......@@ -334,6 +334,7 @@ class TaskController extends AdminController
$start = 'src="';
$end = '" alt';
$pattern = '/' . preg_quote($start) . '(.*?)' . preg_quote($end) . '/';
ini_set('pcre.backtrack_limit', '2097152');
preg_match_all($pattern, $form->input('guide'), $matches);
$images = '';
foreach ($matches[1] as $v) {
......@@ -395,6 +396,7 @@ class TaskController extends AdminController
$start = 'src="';
$end = '" alt';
$pattern = '/' . preg_quote($start) . '(.*?)' . preg_quote($end) . '/';
ini_set('pcre.backtrack_limit', '2097152');
preg_match_all($pattern, $param['guide'], $matches);
$images = '';
foreach ($matches[1] as $v) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment