Help with .htaccess

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • lemarx
    Registered User
    • Jul 2002
    • 12

    #1

    Help with .htaccess

    May be somebody can help me. What I need write in my .htaccess ?
    I need what on my URL and directory ex. (www.someurl.com/somedirectory/) have access visitors from specific URL and pages ex. (www.specificurl.com/specificpage.html). If they come not from this cpecific location then they must be redirected to another specific URL, ex. www.yahoo.com.
    Thanks in advance for your assistance.
    Last edited by lemarx; 08-24-2002, 10:38 AM.
  • ckuehn
    Registered User
    • Oct 2001
    • 5

    #2
    i think it is not possible to check the referer with the htaccess.

    you can build a php tool ( for example ) what checks the referer of the user. if the referer is one of the special urls than you can show the content to the user and if not you can show an error or something else ...

    -ck

    Comment

    • kinkyplace
      Confirmed User
      • Mar 2002
      • 217

      #3
      Originally posted by ckuehn
      i think it is not possible to check the referer with the htaccess.

      you can build a php tool ( for example ) what checks the referer of the user. if the referer is one of the special urls than you can show the content to the user and if not you can show an error or something else ...

      -ck
      It IS possible, I'm just writing a page explaining how to do different things with htaccess, I'll post the URL here when I'm done.

      Comment

      • kinkyplace
        Confirmed User
        • Mar 2002
        • 217

        #4
        I have the beginning of my htaccess tutorial: you can find what you wanted there:

        http://www.kinky-place.com/stuff/resourcesfs.htm

        Comment

        • lemarx
          Registered User
          • Jul 2002
          • 12

          #5
          Thanks for your help.
          I was solve this problem this way:

          RewriteEngine On
          RewriteCond %{REQUEST_URI} /somedirectory/
          RewriteCond %{HTTP_REFERER} !https://www.some-new-url.com/somedir.../somepage.html [NC]
          RewriteRule .* /deny.html [L]

          Comment

          • lemarx
            Registered User
            • Jul 2002
            • 12

            #6
            Originally posted by kinkyplace
            I have the beginning of my htaccess tutorial: you can find what you wanted there:

            http://www.kinky-place.com/stuff/resourcesfs.htm
            Thanks kinkyplace,
            Just want ask about new things and find answers on your tutorial.

            Comment

            Working...