Difference between revisions of "Creating Required Joomla Menu Items"
Line 22: | Line 22: | ||
* create menu items only for last level categories | * create menu items only for last level categories | ||
* create menu items for all categories | * create menu items for all categories | ||
− | |||
The third option is recommended because then none of the category URLs will have ID numbers and urls will include the full category structure. | The third option is recommended because then none of the category URLs will have ID numbers and urls will include the full category structure. | ||
Line 37: | Line 36: | ||
*After you click on the menu type, you will need to choose a category from the dropdown. | *After you click on the menu type, you will need to choose a category from the dropdown. | ||
− | *After you created menu items for all categories, go to JReviews administration and click on the "Clear Cache" link in the left menu. This is necessary because JReviews stores a cached version of the menu system to improve performance. | + | *After you created menu items for all categories, go to JReviews administration and click on the "Clear Cache & File Registry" link in the left menu. This is necessary because JReviews stores a cached version of the menu system to improve performance. |
− | With this setup, you will have a "perfect" | + | With this setup, you will have a "perfect" URL structure, for example: |
*<span style="color: blue">example.com/category-name</span> | *<span style="color: blue">example.com/category-name</span> | ||
*<span style="color: blue">example.com/category-name/subcategory-name</span> | *<span style="color: blue">example.com/category-name/subcategory-name</span> | ||
Line 59: | Line 58: | ||
*After you click on the menu type, you will need to choose a category from the dropdown. | *After you click on the menu type, you will need to choose a category from the dropdown. | ||
− | *After you created menu items for all categories, go to JReviews administration and click on the "Clear Cache" link in the left menu. This is necessary because JReviews stores a cached version of the menu system to improve performance. | + | *After you created menu items for all categories, go to JReviews administration and click on the "Clear Cache & File Registry" link in the left menu. This is necessary because JReviews stores a cached version of the menu system to improve performance. |
Revision as of 21:52, 17 September 2013
Contents
All listings and articles in Joomla should have a parent menu item, otherwise their URLs have ugly "/component/content/article/" segment and it is not possible to assign modules to those pages.
Without a parent menu item, the listing URL will look similar to this:
- example.com/component/content/article/49-category-name/subcategory-name/305-listing-title
JReviews uses Joomla's content system for listings and because of this the parent menu item of listings must be a Joomla Category menu item. After you create those menu items, the "/component/content/article/" segment in URLs will be replaced with the titles of category menu items.
Starting with JReviews 2.4.10 version, those Joomla Category menu items can be used as the main navigation of your site if you enable the JReviews SEF Plugin. In this case, create Joomla Category menu items in the main menu of your site.
If you don't enable the JReviews SEF Plugin, you will need to create required Joomla category menu items in a "hidden" menu that isn't shown on your site and for the main menu of the site create separate JReviews Category List menu items.
Choosing a good menu item structure is important because the title aliases of those menu items will be used in URLs of listings. You have a choice:
- create menu items only for top level categories
- create menu items only for last level categories
- create menu items for all categories
The third option is recommended because then none of the category URLs will have ID numbers and urls will include the full category structure.
Read Using JReviews SEF Plugin for more info.
- In Joomla administration go to the main menu of your site where you want to display the Categories and click the New button in the toolbar.
- Next click on Select button and you will get this popup with the list of available menu item types, choose Category Blog or Category List (it is not important which one):
- After you click on the menu type, you will need to choose a category from the dropdown.
- After you created menu items for all categories, go to JReviews administration and click on the "Clear Cache & File Registry" link in the left menu. This is necessary because JReviews stores a cached version of the menu system to improve performance.
With this setup, you will have a "perfect" URL structure, for example:
- example.com/category-name
- example.com/category-name/subcategory-name
- example.com/category-name/subcategory-name/listing-title
- In the Joomla administration click on Menus => Menu Manager and to create a new menu click on New.
- In the next screen enter the Title and Menu Type:
- After the Hidden Menu is created, click New in the toolbar to create the first menu item.
- Next click on Select button and you will get this popup with the list of available menu item types, choose Category Blog or Category List (it is not important which one):
- After you click on the menu type, you will need to choose a category from the dropdown.
- After you created menu items for all categories, go to JReviews administration and click on the "Clear Cache & File Registry" link in the left menu. This is necessary because JReviews stores a cached version of the menu system to improve performance.
With this setup, the listing URLs will include the category names that you created in this Hidden Menu, for example:
- example.com/category-name/ID-listing-title
But the categories will have a separate URL structure based on how you create JReviews Category List menu items in the main menu of your site.