正在显示
1 个修改的文件
包含
1 行增加
和
0 行删除
| @@ -193,6 +193,7 @@ class TranslateLogic extends BaseLogic | @@ -193,6 +193,7 @@ class TranslateLogic extends BaseLogic | ||
| 193 | $trimmedString = preg_replace('/\s+/', ' ', $content); | 193 | $trimmedString = preg_replace('/\s+/', ' ', $content); |
| 194 | $contentData[] = $trimmedString; | 194 | $contentData[] = $trimmedString; |
| 195 | } | 195 | } |
| 196 | + $textContentArray = array_unique($textContentArray); | ||
| 196 | $contentData = array_values($textContentArray); | 197 | $contentData = array_values($textContentArray); |
| 197 | $pattern = '/<meta\s+[^>]*name=[\'"](keywords|description)[\'"][^>]*content=[\'"]([^\'"]+)[\'"]>/i'; // 匹配 name 为 "keywords" 或 "description" 的 meta 标签的正则表达式 | 198 | $pattern = '/<meta\s+[^>]*name=[\'"](keywords|description)[\'"][^>]*content=[\'"]([^\'"]+)[\'"]>/i'; // 匹配 name 为 "keywords" 或 "description" 的 meta 标签的正则表达式 |
| 198 | $matches = array(); | 199 | $matches = array(); |
-
请 注册 或 登录 后发表评论