logo
Apache Lounge
Webmasters

 

About Forum Index Downloads Search Register Log in RSS X


Keep Server Online

If you find the Apache Lounge, the downloads and overall help useful, please express your satisfaction with a donation.

or

Bitcoin

A donation makes a contribution towards the costs, the time and effort that's going in this site and building.

Thank You! Steffen

Your donations will help to keep this site alive and well, and continuing building binaries. Apache Lounge is not sponsored.
Post new topic   Forum Index -> Apache View previous topic :: View next topic
Reply to topic   Topic: mod_write
Author
kenoli



Joined: 11 Apr 2017
Posts: 1
Location: USA, San Francisco

PostPosted: Tue 11 Apr '17 17:54    Post subject: mod_write Reply with quote

I am trying to learn how to use mod_rewrite.

As a practice exercise, I am trying to send blackbearranch.org to a file in the same directory where the index.php file is located named hello.php.

I have tried all of the following and get a 404 file not found error:

<IfModule mod_rewrite.c>
RewriteEngine On
RewriteRule blackbearranch.org/Begin blackbearranch.org/hello.php
</IfModule>

<IfModule mod_rewrite.c>
RewriteEngine On
RewriteRule ^blackbearranch.org/Begin$ blackbearranch.org/hello.php
</IfModule>

<IfModule mod_rewrite.c>
RewriteEngine On
RewriteRule ^blackbearranch.org/Begin$ ./hello.php
</IfModule>

<IfModule mod_rewrite.c>
RewriteEngine On
RewriteRule blackbearranch.org/Begin hello.php
</IfModule>

<IfModule mod_rewrite.c>
RewriteEngine On
RewriteRule ^blackbearranch.org/Begin$ hello.php
</IfModule>

and more.

Can someone help me?

Thanks,

--Kenoli
Back to top
James Blond
Moderator


Joined: 19 Jan 2006
Posts: 7288
Location: Germany, Next to Hamburg

PostPosted: Sun 14 May '17 12:39    Post subject: Reply with quote

Is blackbearranch.org a domain or a directory or a file?
Back to top


Reply to topic   Topic: mod_write View previous topic :: View next topic
Post new topic   Forum Index -> Apache