We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 53460
    • 69 Posts
    I've hit a wall. I copied exactly what I'm doing on another installation, which works, but the menu isn't working properly on my local installation.

    I'm building my primary menu and when I preview the site, everything links to a subdirectory of the previous page (i.e. www.yoursite.com/contact, then www.yoursite.com/contact/about. Instead of www.yoursite.com/about). This is what I have for my main menu:

    				<nav id="nav">
    					[[Wayfinder? &startId=`0` &level=`1` &rowTpl=`mainMenuItemTpl` &outerTpl=`mainMenuTpl`]]
    				</nav>
    


    rowTpl:
    					<li [[+wf.id]]>
    					    <a href="[[+wf.link]]" class="skel-layers" title="[[+wf.title]]" [[+wf.attributes]]>
    					        <span class="icon [[+fontAwesomeIcon]]">[[+wf.linktext]]</span>
    			            </a>[[+wf.wrapper]]
    	                </li>


    outerTpl:
    <ul>
    [[+wf.wrapper]]
    </ul>


    I have friendly urls enabled and each resource checked off as a "container" to remove the .html extension.

    Any thoughts?

    Thanks in advance.

    This question has been answered by BobRay. See the first response.

    [ed. note: jeffsydor last edited this post 6 years, 5 months ago.]
    • discuss.answer
      • 3749
      • 24,544 Posts
      I'm not completely clear on what the problem is, but it sounds like you may need to turn off the use_alias_path System Setting, then click on Manage -> Clear Cache -> Refresh URIs.

      Also, make sure you have this tag (with the exclamation point) in the head section of all Templates:

      <base href="[[!++site_url]]" />


      If the site is in a subdirectory, you often have to include the subdirectory in the RewriteBase line of .htaccess for a localhost install. Make sure it ends with a slash.
        Did I help you? Buy me a beer
        Get my Book: MODX:The Official Guide
        MODX info for everyone: http://bobsguides.com/modx.html
        My MODX Extras
        Bob's Guides is now hosted at A2 MODX Hosting
        • 53460
        • 69 Posts
        It was the base link. I completely forgot about that.

        Thank you!
          • 3749
          • 24,544 Posts
          I'm glad I could help. smiley
            Did I help you? Buy me a beer
            Get my Book: MODX:The Official Guide
            MODX info for everyone: http://bobsguides.com/modx.html
            My MODX Extras
            Bob's Guides is now hosted at A2 MODX Hosting