We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 51267
    • 25 Posts
    Folks,

    Apologies for another friendly url question but the stick above makes no sense to me and I have never had the need to deal with .htaccess.

    Currently I have a modx site installed on the root of domain.ie.

    My .htaccess reads as


    # For full documentation and other suggested options, please see
    # http://svn.modxcms.com/docs/display/MODx096/Friendly+URL+Solutions
    # including for unexpected logouts in multi-server/cloud environments
    # and especially for the first three commented out rules

    #php_flag register_globals Off
    #AddDefaultCharset utf-8
    #php_value date.timezone Europe/Moscow

    Options +FollowSymlinks
    RewriteEngine On
    RewriteBase /

    # Fix Apache internal dummy connections from breaking [(site_url)] cache
    RewriteCond %{HTTP_USER_AGENT} ^.*internal\ dummy\ connection.*$ [NC]
    RewriteRule .* - [F,L]

    # Rewrite domain.com -> www.domain.com -- used with SEO Strict URLs plugin
    #RewriteCond %{HTTP_HOST} .
    #RewriteCond %{HTTP_HOST} !^www\.example\.com [NC]
    #RewriteRule (.*) http://www.example.com/$1 [R=301,L]

    # Exclude /assets and /manager directories and images from rewrite rules
    RewriteRule ^(manager|assets)/*$ - [L]
    RewriteRule \.(jpg|jpeg|png|gif|ico)$ - [L]

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

    # Reduce server overhead by enabling output compression if supported.
    #php_flag zlib.output_compression On
    #php_value zlib.output_compression_level 5

    Do I change some value here? shocked

    I would like the output to be:
    domain.ie/alias.html

    Edit this is for Evo 1.04
      • 12028
      • 152 Posts
      If you go to Tools -> Configuration -> Friendly URLS in Evo, and make the changes there to get domain.ie/alias.html, it should work, as long as your ht.access are renamed to .htaccess.
      But you should also edit the content in the .htaccess so the lines:
      #RewriteCond %{HTTP_HOST} .
      #RewriteCond %{HTTP_HOST} !^www\.example\.com [NC]
      #RewriteRule (.*) http://www.example.com/$1 [R=301,L]

      match your domain. This is to differentiate between http://www.domain.tld and http://domain.tld. Just remember to remove the # in front at the lines, so the server read the lines.
        - A small step for mankind, so why not take two...

        Working with web production, graphic design/workflow, photo and education - but are trying to get a life in between!