Add or remove links to the navigation bar depending on screen size in 5.7

This tutorial is over a year old and may not apply to your version of Concrete CMS.
Apr 27, 2015

Step 1 Edit the autonav block. In the view.php (Make sure you choose the correct view.php. If you are using a template like the responsive_header_navigation you will have to edit the view.php in that folder) you need to enable the $navItem->attrClass attribute. Line 88 you need to un comment the following

if (!empty($ni->attrClass)) {
    //class that can be set by end-user via the 'nav_item_class' custom page attribute
    $classes[] = $ni->attrClass;


if (!empty($ni->attrClass)) {
    //class that can be set by end-user via the 'nav_item_class' custom page attribute
    $classes[] = $ni->attrClass;

Step 2 Create a Page attribute. In the dashboard Pages & themes, Attributes and create a Text Attribute called nav_item_class. This is documented in the view.php file.

Then for the page depending on what screen size you want to hide or show the link you can use some bootstrap css.

Example if you want to add a facebook and twitter link to a responsive mobile menu you would add them as external links within the sitemap. Then in the dashboard go Sitemap, Page Search and choose attributes for the relevant link. Add the nav_item_class to the page and enter visible-xs

More Bootstrap Available classes are available at

Recent Tutorials
Using the Concrete Migration Tool Addon
Apr 27, 2023

How to use the Concrete CMS Migration Tool

How To Add Page Last Updated To Your Concrete CMS Pages
Mar 7, 2023

Concrete CMS has a page attribute you can add to a global area called "Page Date Modified." Here's how to add it

How To Exclude Subpages from Navigation
Dec 24, 2022

How to exclude subpages from navigation - useful for a news or blog link in your main navigation where you don't want all the subpages to appear in a drop down menu.

How Can I Change The Maximum Size Of Uploaded files
Dec 13, 2022

This tutorial explains how to update your php settings.

Updating Concrete Themes from Version 8 to Version 9
Nov 24, 2022

This tutorial covers commonly encountered issues when upgrading a Concrete CMS theme from version 8 to version 9

Transferring ownership of an add-on and a theme
Nov 15, 2022
By katzueno.

If you encounter a Concrete CMS add-on or theme that you love but not being maintained, you may want to ask the author to help or take over the add-on or theme. Here is the quick step-by-step guide of how to transfer the ownership.

Was this information useful?
Thank you for your feedback.