diff --git a/CrossDown/Core.py b/CrossDown/Core.py index a4ab04f..e421854 100644 --- a/CrossDown/Core.py +++ b/CrossDown/Core.py @@ -145,7 +145,7 @@ class Tag(Treeprocessor): elif header.tag == 'ul': # 是无序列表 for i in header: # 遍历列表内容 try: - i[0].set('id', i[0].text.split(' ')[0]) # 是目录 + i[0].set('href', '#' + i[0].text.split(' ')[0]) # 是目录 except IndexError: pass # 是普通的无序列表 diff --git a/README.html b/README.html index c971d65..8531817 100644 --- a/README.html +++ b/README.html @@ -28,17 +28,17 @@