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

    Amo el viajar a la Argentina (is that right? I think it is grin)

    Anyway, let’s back up a step to diagnose this. What webserver is your site set up on? Is it Apache? If so, if mod_rewrite turned on and available for you to use? Do you have access to the Apache error_log to see what the problem is as Apache reports it?
      • 36747
      • 138 Posts
      vbrilon, your spanish is as good as my english smiley

      My server config is the following:

      System 	Linux tweety 2.6.16.20 #5 SMP PREEMPT Sat Jun 17 11:26:12 ART 2006 i686
      Server API 	Apache
      PHP Version 4.3.10


      mod_rewrite appears in the loaded modules! Its that enough if I want to use it?

      I think that is better if you see http://sabf.itba.edu.ar/try.php phpinfo is located there. The server is own by the university and the page is a project of some students and we don’t have access to the configuration of the server. In addition the sysadmin don’t know much about Apache or mod_rewrite.

      With ’RewriteEngine on’ I’m getting 403 on everyfile in the site, in addition I cant see the logs.

      cheers
        patagonia, argentina
        • 36747
        • 138 Posts
        anyone had any idea? vbrilon?

        cheers
        emi
          patagonia, argentina
          • 25663 MODX Staff
          • 12,272 Posts
          Victor won’t be back until next week. Had a quick trip to Finland for work. smiley
            Ryan Thrash, MODX Co-Founder
            Follow me on Twitter at @rthrash or catch my occasional unofficial thoughts at thrash.me
            • 7923
            • 4,213 Posts
            In the meanwhile... Did you try any of these without the RewriteBase? Or with "RewriteBase /"? And you have "RewriteEngine On" there right?


              "He can have a lollipop any time he wants to. That's what it means to be a programmer."
              • 36747
              • 138 Posts
              yes, but it’s not working.... i’m still getting a 403 error

              Forbidden
              You don't have permission to access /index.php on this server.


              From
              RewriteRule ^(.*)$ /var/www/htdocs/vhost/sabf/public_html/index.php?q=$1 [L,QSA]

              to
              RewriteRule ^(.*)$ /index.php?q=$1 [L,QSA]


              with RewriteEngine On or RewriteEngine on. The same result over and over again... The problem is that I don’t know if what I have in my server its enough to use Mod_rewrite, the module it’s only loaded, but it just appears in that list of loaded modules. Many other modules that works have more information in the phpinfo file (http://www.sabf.itba.edu.ar/try.php).

              cheers
              emi
                patagonia, argentina
                • 15109
                • 18 Posts
                the same problem!

                Apache 2.2, MySQL 5, PHP 5.2, rewrite mod is on.

                There is 403 error on every levels of the site
                (my old .htaccess works good).
                  • 34162
                  • 1 Posts
                  Hello everyone.

                  I had a similiar problem with 1&1, whereby it didnt matter what I did with the .htaccess it just didnt work.

                  I tried file paths to root, subdomains and folders.

                  So after digging around in here and generally in the web I found the one I now use.

                  It may help you out, its been tested now on 6 hosts and works perfectly (ref: subdomain, change where needed)

                  Hope it helps

                  RewriteEngine On
                  RewriteBase /
                  #RewriteCond %{HTTP_HOST} ^DOMAINNAME.com [NC]
                  #RewriteRule ^(.*) http://www.DOMAINNAME.com/$1 [R=301,L]
                  
                  #First, remove trailing slash, dot and comma if present. Trailing slash is well-known isuue (duplicity),
                  #trailing dots, commas and so on sometimes happen in forums when URLs are wrongly parsed out
                  #from a sentence. Not 100% implementation, but works fine.
                  RewriteCond %{REQUEST_FILENAME} !-f
                  RewriteCond %{REQUEST_FILENAME} !-d
                  RewriteCond %{REQUEST_URI} !(.*[^/,\.])$
                  RewriteRule ^(.*)[/\.,]$ /$1 [L,R=301]
                  
                  #this is my experimental feature - delete it
                  #if the file exists in /cache (not /assets/cache),
                  #output it instead of php
                  RewriteCond cache%{REQUEST_URI}.html -F
                  RewriteRule .* cache%{REQUEST_URI}.html [L,QSA]
                  
                  #this is the standard nice url
                  RewriteCond %{REQUEST_FILENAME} !-f
                  RewriteCond %{REQUEST_FILENAME} !-d
                  RewriteRule ^(.*)$ index.php?q=$1 [L,QSA]
                  
                    • 15109
                    • 18 Posts
                    so many strings)

                    i checked my apache error log file out and found several interesting records there:
                    [Fri Mar 16 17:07:27 2007] [error] [client 87.240.30.226] Options FollowSymLinks or SymLinksIfOwnerMatch is off which implies that RewriteRule directive is forbidden: K:/site/www/index.php
                    [Fri Mar 16 17:07:27 2007] [error] [client 87.240.30.226] Options FollowSymLinks or SymLinksIfOwnerMatch is off which implies that RewriteRule directive is forbidden: K:/site/www/favicon.ico, referer: http://avel.org.ru/index.php


                    What does "FollowSymLinks or SymLinksIfOwnerMatch" mean and where’s it from?
                      • 28042 ☆ A M B ☆
                      • 24,524 Posts
                      You may want to try adding
                       Options +FollowSymlinks

                      just before the RewriteEngine On line.

                      http://corz.org/serv/tricks/htaccess2.php

                        Studying MODX in the desert - http://sottwell.com
                        Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
                        Join the Slack Community - http://modx.org