Is there a way to insert the Page Name or Meta Title as the Title Tag in Autonav to make it more compliant?
Permalink
Where/how would one modify Autonav to grab the Page Title and insert it into the link as the title tag? It includes Target and Class but not Title and that'd go a long way to improving internal link structure in the eyes of the W3C standards.
You can copy the /concrete/blocks/autonav/view.php out to /application/blocks/autonav/view.php and change line 120 to look like this to achieve that. Remember to clear your cache if it's turned on to see this change
Thank you for the response/help! Hmmm... I swapped out the code and moved the base autonav view.php file to the application/blocks/autonav directory, turned off all caching, cleared cache, refreshed the page, turned caching back on, and cleared the cache one more time and it still isn't displaying. The website ishttp://www.i17tbirdstorage.com . The site is using a modified Mortar template and I am using one of the Autonav templates it comes with. Given that nothing has changed, I'm wondering if the Autonav template view.php is interfering perhaps or where the change needs to be made?
<?php defined('C5_EXECUTE') or die("Access Denied."); $c = Page::getCurrentPage(); //Create an array of parent cIDs so we can determine the "nav path" of the current page $inspectC = $c; $selectedPathCIDs = array($inspectC->getCollectionID()); $parentCIDnotZero=true; while ($parentCIDnotZero) { $cParentID = $inspectC->cParentID; if (!intval($cParentID)) { $parentCIDnotZero=false; } else { if ($cParentID != HOME_CID) { $selectedPathCIDs[] = $cParentID; //Don't want home page in nav-path-selected }
Viewing 15 lines of 255 lines. View entire code block.
Yes, if you are using a Custom Template you will need to copy that file into the application directory in the correct structure and make the change there.