diff options
| -rw-r--r-- | libs/Contents.php | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/libs/Contents.php b/libs/Contents.php index ead2293..2d27671 100644 --- a/libs/Contents.php +++ b/libs/Contents.php @@ -233,6 +233,11 @@ class Contents $id = str_replace(' ','_',$id); $id = str_replace('&','_',$id); $id = str_replace('?','_',$id); + $id = str_replace("'",'_',$id); + $id = str_replace('"','_',$id); + $id = str_replace('’','_',$id); + $id = str_replace('“','_',$id); + $id = str_replace('?','_',$id); return '<h'.$matchs[1].$matchs[2].' id="'.$id.'">'.$matchs[3].'<a href="#'.$id.'" title="章节链接" class="post-toc-link no-line"><i class="iconfont icon-paragraph"></i></a></h'.$matchs[1].'>'; } |
