We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 44711
    • 3 Posts
    Hi

    I'm having a problem when turning on Friendly Urls.
    I have installed modx-2.2.8. I'm very happy with everything, everything is working well.
    T have a number of web pages in the cms and in the browser address bar they have a URL as:
    Page 1: Home page (address below)
    http://www.mywebsite_address/modxcms3/

    Page 2: About page (address below)
    http://www.mywebsite_address/modxcms3/index.php?id=2

    Page 3: Portfolio page (address below)
    http://www.mywebsite_address/modxcms3/index.php?id=3

    In the head of the web pages scripting is: <base href="[[!++site_url]]" />

    The .htaccess:
    # The Friendly URLs part
    #RewriteCond %{REQUEST_FILENAME} !-f
    #RewriteCond %{REQUEST_FILENAME} !-d
    #RewriteRule ^(.*)$ index.php?q=$1 [L,QSA]

    RewriteCond %{REQUEST_URI} \.html$
    RewriteRule ^(.*)\.html$ $1 [R=301,L]

    RewriteRule ^index\.php$ - [L]
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule ^(.*)$ index.php?q=$1 [L,QSA]
    #RewriteRule . /index.php [L]

    The problem I am having is when the system settings are changed to:
    Use Friendly URLs = Yes
    Use Friendly Alias Path = Yes

    I have cleared the system cache.

    When clicking on a page link I get a browser message of:

    Page 2: About page (get this message below)
    http://www.mywebsite_address/modxcms3/about.html
    The requested URL /modxcms3/about.html was not found on this server.

    Page 3: Portfolio page (get this message below)
    http://www.mywebsite_address/modxcms3/portfolio.html
    The requested URL /modxcms3/portfolio.html was not found on this server.

    Page 1: Home page
    http://www.mywebsite_address/modxcms3/
    If you type this address into the browser address bar this will bring up the home page. This OK.

    Can someone help with this please.
      • 44711
      • 3 Posts
      Hi

      I'm having a problem when turning on Friendly Urls.
      I have installed modx-2.2.8. I'm very happy with everything, everything is working well.
      T have a number of web pages in the cms and in the browser address bar they have a URL as:
      Page 1: Home page (address below)
      http://www.mywebsite_address/modxcms3/

      Page 2: About page (address below)
      http://www.mywebsite_address/modxcms3/index.php?id=2

      Page 3: Portfolio page (address below)
      http://www.mywebsite_address/modxcms3/index.php?id=3

      In the head of the web pages scripting is: <base href="https://forums.modx.com/" />

      The .htaccess:
      # The Friendly URLs part
      #RewriteCond %{REQUEST_FILENAME} !-f
      #RewriteCond %{REQUEST_FILENAME} !-d
      #RewriteRule ^(.*)$ index.php?q=$1 [L,QSA]

      RewriteCond %{REQUEST_URI} \.html$
      RewriteRule ^(.*)\.html$ $1 [R=301,L]

      RewriteRule ^index\.php$ - [L]
      RewriteCond %{REQUEST_FILENAME} !-f
      RewriteCond %{REQUEST_FILENAME} !-d
      RewriteRule ^(.*)$ index.php?q=$1 [L,QSA]
      #RewriteRule . /index.php [L]

      The problem I am having is when the system settings are changed to:
      Use Friendly URLs = Yes
      Use Friendly Alias Path = Yes

      I have cleared the system cache.

      When clicking on a page link I get a browser message of:

      Page 2: About page (get this message below)
      http://www.mywebsite_address/modxcms3/about.html
      The requested URL /modxcms3/about.html was not found on this server.

      Page 3: Portfolio page (get this message below)
      http://www.mywebsite_address/modxcms3/portfolio.html
      The requested URL /modxcms3/portfolio.html was not found on this server.

      Page 1: Home page
      http://www.mywebsite_address/modxcms3/
      If you type this address into the browser address bar this will bring up the home page. This OK.

      Can someone help with this please.


      ------------------------------------

      I thought I had solved this problem by adding the below to the .htaccess

      Options +FollowSymlinks
      RewriteEngine On
      RewriteBase /modxcms3/

      Now the browser addresses are:
      Page 2: About page
      http://www.mywebsite_address/modxcms3/about

      Page 3: Portfolio page
      http://www.mywebsite_address/modxcms3/portfolio

      Now the page URLs changes in the browser address to the link you click but the web page will not change it stays on the index page even though the browser address has changed.

      Hope someone can help with this.
      [ed. note: xar05mod last edited this post 13 years, 1 month ago.]
        • 33987 ☆ A M B ☆
        • 197 Posts
        What kind of server are you on? Linux with Apache or Windows with IIS?

        Your .htaccess looks a bit different than the default htaccess, which works just fine.
          Sterc Internet & Marketing | MODX Founding Partner | Chairman of the MODX Advisory Board

          In need of a MODX consult? Try our MODX Developers Experts!
          • 44711
          • 3 Posts
          Quote from: nomark at Aug 08, 2013, 01:58 AM
          What kind of server are you on? Linux with Apache or Windows with IIS?

          Your .htaccess looks a bit different than the default htaccess, which works just fine.

          Hi GP

          I've gone back to the default htaccess file and added in
          CheckSpelling On
          RewriteBase /modxcms3

          Its now working fine. Thanks for your reply.
          You try so many different things it tends to get a bit confusing after a while.
          All is working fine now.
            • 33987 ☆ A M B ☆
            • 197 Posts
            Good to hear! Have fun smiley
              Sterc Internet & Marketing | MODX Founding Partner | Chairman of the MODX Advisory Board

              In need of a MODX consult? Try our MODX Developers Experts!