|
@@ -62,6 +62,7 @@ class Article
|
|
|
unset($temp);
|
|
|
}
|
|
|
}
|
|
|
+
|
|
|
if (isset($matches[1])) {
|
|
|
foreach ($matches[1] as $k => $v) {
|
|
|
if (isset($matches[3][$k])) {
|
|
@@ -117,23 +118,23 @@ class Article
|
|
|
$replace[] = array('id' => $v, 'type' => $type, 'content' => $info);
|
|
|
}
|
|
|
}
|
|
|
+ }
|
|
|
|
|
|
-
|
|
|
-
|
|
|
- $content = explode('{replace}', $content);
|
|
|
- $data['content_array'] = array();
|
|
|
-
|
|
|
- foreach ($content as $k => $v) {
|
|
|
- $v = trim($v);
|
|
|
- if (is_numeric($v) && $v >= 0 && isset($replace[$v])) {
|
|
|
- $data['content_array'][] = $replace[$v];
|
|
|
- } elseif ($v) {
|
|
|
- $data['content_array'][] = array
|
|
|
- (
|
|
|
- 'type' => 1,
|
|
|
- 'content' => $v,
|
|
|
- );
|
|
|
- }
|
|
|
+
|
|
|
+
|
|
|
+ $content = explode('{replace}', $content);
|
|
|
+ $data['content_array'] = array();
|
|
|
+
|
|
|
+ foreach ($content as $k => $v) {
|
|
|
+ $v = trim($v);
|
|
|
+ if (is_numeric($v) && $v >= 0 && isset($replace[$v])) {
|
|
|
+ $data['content_array'][] = $replace[$v];
|
|
|
+ } elseif ($v) {
|
|
|
+ $data['content_array'][] = array
|
|
|
+ (
|
|
|
+ 'type' => 1,
|
|
|
+ 'content' => $v,
|
|
|
+ );
|
|
|
}
|
|
|
}
|
|
|
|