- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I would like to include links to hidden categories in my cms static blocks. What is the correct way to do that?
Solved! Go to Solution.
Accepted Solutions
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Use the category link widget.
Let's say, you want to add a link to category with ID 1.
Add this to your cms page/block:
{{widget type="catalog/category_widget_link" anchor_text="Some text" title="Some text" template="catalog/category/widget/link/link_inline.phtml" id_path="category/1"}}
Follow this and you can accomplish what you want.
200+ Premium Magento 2 Extensions Need help? Hire Magento Developer
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Use the category link widget.
Let's say, you want to add a link to category with ID 1.
Add this to your cms page/block:
{{widget type="catalog/category_widget_link" anchor_text="Some text" title="Some text" template="catalog/category/widget/link/link_inline.phtml" id_path="category/1"}}
Follow this and you can accomplish what you want.
200+ Premium Magento 2 Extensions Need help? Hire Magento Developer
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Re: How to include a link to a category in a static block
Hi,
i have links to the categories in the text of my home page and inserted them with the "insert widget" button so that the code is as shown above.
But i want to have a comma after one Link and there is a whitespace shown. Can i fix this?
Thanks in advance,
hesa.