mirror of
https://github.com/getpelican/pelican.git
synced 2025-10-15 20:28:56 +02:00
More granular control of tags and categories slugs. Fixes #1873
- add TAG_SUBSTITUTIONS AND CATEGORY_SUBSTITURIONS settings - make slugify keep non-alphanumeric characters if configured
This commit is contained in:
parent
70665ea0fa
commit
648165b839
8 changed files with 123 additions and 8 deletions
|
|
@ -172,6 +172,7 @@ class Content(object):
|
|||
'lang': getattr(self, 'lang', 'en'),
|
||||
'date': getattr(self, 'date', SafeDatetime.now()),
|
||||
'author': self.author.slug if hasattr(self, 'author') else '',
|
||||
'tag': self.tag.slug if hasattr(self, 'tag') else '',
|
||||
'category': self.category.slug if hasattr(self, 'category') else ''
|
||||
})
|
||||
return metadata
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue