The categories does quite well at grouping together pages. But sometimes I’d like my page to link to another page. This is done using a Tag-Plugin called Post_Link
To link to another page in your hexo page stack, use the following structure:
1 | {% post_link VB-Net-FileSystemWatcher [VB.Net - FileSystemWatcher] %} |
Arguments
- Brace/Parens - surrounds what are called Tag-Plugins. They are very poorly documented but seem to work.
- Post_link – is a command telling Hexo to turn this into a link to another hexo page. This is a Tag-Plugin. There are quite a few
- VB-Net-FileSystemWatcher – is a file we are linking to
- [VB.Net – FileSystemWatcher] - is a title, or link description. The Brackets are not required..
What about spaces ?
A statement like this
1 | * {% post_link SQL Server - Select - Cross Apply [SQL Server - Select - Cross Apply] %} |
When you do a “hexo server” you’ll get a vague error message:
1 | PS E:\d\dev\hexo\MarklandK> hexo server |
The solution the first argument of post_link should match the filename, not the title. For example
1 | * {% post_link SQL-Server-Select-Cross-Apply [SQL Server - Select - Cross Apply] %} |
References
- https://hexo.io/docs/tag-plugins.html#Include-Posts – hexo documentation
- https://github.com/hexojs/hexo/issues/2176 a website giving me a clue of what the hexo documentation was trying to say