Kernc 246fd05d44 Have relevant plugins use all_generators_finalized signal лет назад: 10
..
Readme.md 30638d8ac4 Update Readme.md лет назад: 11
__init__.py 943e590c24 Read more link plugin -- initial commit лет назад: 11
read_more_link.py 246fd05d44 Have relevant plugins use all_generators_finalized signal лет назад: 9
requirements.txt 943e590c24 Read more link plugin -- initial commit лет назад: 11

Readme.md

Read More Link

Author: Vuong Nguyen (http://vuongnguyen.com)

This plugin inserts an inline "read more" or "continue" link into the last html element of the object summary.

For more information, please visit: http://vuongnguyen.com/creating-inline-read-more-link-python-pelican-lxml.html

Requirements

lxml - for parsing html elements

Settings

# This settings indicates that you want to create summary at a certain length
SUMMARY_MAX_LENGTH = 50

# This indicates what goes inside the read more link
READ_MORE_LINK = None (ex: '<span>continue</span>')

# This is the format of the read more link
READ_MORE_LINK_FORMAT = '<a class="read-more" href="/{url}">{text}</a>'