MODX Community

How Do I Make a Container That is Only a Container

Is there a way to make my container that does not link to a landing page or have content.
I only want to use it to provide the child links in my main menu.

If you add no content it will have no content. You could go a step further and set the template to (empty) and then it will be nothing but a blank page. If you don’t even want it to load a blank page you can set the Resource Type to Weblink and either provide the ID number of the page where you want it to redirect or enter a URL. Does that help?

Thanks for the quick response. This sort of helps. I used to use FirstChildReDirect, which accomplished to loading of a specific page. I was hoping to not force the visitor to a specific page, but rather have them be able to select from the list of items in the drop menu. Here is a link to info about the AddOn. FirstChildReDirect I may just forego the child menu, and just do a landing page. It seem odd to have a top-level item that reDirects to a page and thus prevents the user from actually using the drop menu.

If I understand you correctly your issue is more the menu and not the resource structure. If you use pdoMenu or something similar to build your navigation you can use a custom template for container resources which enables you to make them not clickable (regardless of their actual content).

Thank you for responding. I really appreciate the feedback. I do use pdoMenu… think I have done this in the past, but cannot find my notes. Yesterday… it was faster to code out a landing page and simply hide the children from the nav menu—rather than continuing to research a solution. I will have to circle back to this later.