This commit is contained in:
Zergling_man 2021-10-29 05:53:33 +11:00
parent b17c34142c
commit e8ab008754

View File

@ -60,4 +60,4 @@ def chapter(bookurl,chapnum):
book=models.Book.objects.filter(url=bookurl)[0]
chapter=models.Chapter.objects.filter(book=book,number=int(chapnum))[0]
text='<p>'+chapter.contents.replace('<','&lt;').replace('>','&gt;').replace('\n\n','</p><p>').replace('\n','<br/>')+'</p>'
return {'title':chapter,'content':'<p>Navigation buttons will come later...</p>\n'+chapter.contents,'date':chapter.added}
return {'title':chapter,'content':'<p>Navigation buttons will come later...</p>\n'+text,'date':chapter.added}