mirror of
https://gitee.com/ulthon/ulthon_information.git
synced 2026-07-09 06:02:49 +08:00
fix(phone-image): 修复XSS注入、正则兼容性、render锁稳定性和缓存清理
T1: XSS修复 - PHP模板注入改用json_encode,poster URL转义处理
T2: fontSize NaN修复 - parseInt统一处理,lookbehind正则替换为兼容方案
T3: render锁稳定性 - insertPageBreak/removePageBreak添加15次重试上限,
fontsReady添加catch处理,_pending递归添加错误捕获
T4: 缓存清理 - init()清空缓存,render()超过3倍blocks数自动清理
This commit is contained in:
@@ -187,13 +187,13 @@
|
||||
|
||||
var postData = {
|
||||
postId: {$post.id},
|
||||
title: '{$post.title|raw}',
|
||||
desc: '{$post.desc|default=""}',
|
||||
coverText: '{$post->getData("cover_text")|default=""}',
|
||||
title: <?php echo json_encode($post->title ?? ''); ?>,
|
||||
desc: <?php echo json_encode($post->desc ?? ''); ?>,
|
||||
coverText: <?php echo json_encode($post->getData('cover_text') ?? ''); ?>,
|
||||
contentHtml: $('#post-content-html').html(),
|
||||
poster: '{$post.poster|default=""}',
|
||||
authorName: '{$post.author_name|default=""}',
|
||||
createTime: '{$post.create_time_text|default=""}',
|
||||
poster: <?php echo json_encode($post->poster ?? ''); ?>,
|
||||
authorName: <?php echo json_encode($post->author_name ?? ''); ?>,
|
||||
createTime: <?php echo json_encode($post->create_time_text ?? ''); ?>,
|
||||
categoryName: ''
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user