[EMAIL PROTECTED] Rewrite/RedirectMatch Issues

2006-02-03 Thread Jason Williard
I have been having trouble getting some Rewrites or Redirects to work.  Here
is what I am trying to do:

http://weather.domain.com/ - http://www.domain.com/weather/
http://weather.domain.com/# - http://www.domain.com/weather/#
http://weather.domain.com/@ - http://www.domain.com/weather/@

The # represents a string of 5 digits (US zip code).  The @ string
represents any text (aimed at the name of a city).

Here is what I currently have.  I've gone through many changes, but this
seems to be the closest to working properly:

  Redirect/index.php  http://www.domain.com/weather/
  RedirectMatch   ^/([0-9]{5})http://www.domain.com/weather/$1
  RedirectMatch   ^/([A-Za-z]+)   http://www.domain.com/weather/$1


The problem with this is the last line is interpreting index.php as
/index and appending that to the end.  The second line works perfectly.
How can I get the last line to work without seeing index.php, or index, as a
match?


Also, when it gets to http://www.domain.com/weather/$1, I am experiencing a
similar issue.  The images/ folder is in a folder called weather/.  So, with
the rules that I have in place, the images are not showing up.  I'd like to
know if there is a way to follow the rules while excluding the weather
folder.

Here are the rules for that:

RewriteRule  ^weather/$
cgi-bin/weather/hw3.cgi?forecast=asus01use_map=us_c_sm_albers2 [NC]
RewriteRule  ^weather/([0-9]{5})cgi-bin/weather/hw3.cgi?pands=$1
[NC]
RewriteRule  ^weather/([A-Za-z]+)   cgi-bin/weather/hw3.cgi?pands=$1
[NC]



Thank You,
Jason Williard



-
The official User-To-User support forum of the Apache HTTP Server Project.
See URL:http://httpd.apache.org/userslist.html for more info.
To unsubscribe, e-mail: [EMAIL PROTECTED]
  from the digest: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



[EMAIL PROTECTED] Troubles w/mod_rewrite

2006-01-19 Thread Jason Williard
I have a site that shows weather forecasts.  I would like create a
RewriteRule to redirect to the proper URL when someone appends their zipcode
to the base url.

i.e. http://weather.domain.com/12345 -
http://www.domain.com/cgi-bin/weather/weather.pl?zip=12345

So far, I have tried several methods but cannot get it to work.  Here are my
current rules in the .htaccess file:

RewriteEngine   On
RewriteRule ^/([^/]*)
http://www.domain.com/cgi-bin/weather/weather.pl?zip=$1 [PT,QSA]

I have also tried each of the following:

RewriteRule ^/([^/][0-9])
http://www.searching.com/cgi-bin/weather/weather.pl?zip=$1 [PT,QSA]
RewriteRule ^/([^/][0-9]{5})
http://www.searching.com/cgi-bin/weather/weather.pl?zip=$1 [PT,QSA]
RewriteRule ^/([0-9]{5})
http://www.searching.com/cgi-bin/weather/weather.pl?zip=$1 [PT,QSA]
RewriteRule ^/([0-9])
http://www.searching.com/cgi-bin/weather/weather.pl?zip=$1 [PT,QSA]

None of these have worked.  I simply get a 404 Not Found error.  However, I
know that mod_rewrite is working as I had another rule in place for
redirecting anything that goes to that page to the default URL. 

Any ideas?

---
Thank You,
Jason Williard


-
The official User-To-User support forum of the Apache HTTP Server Project.
See URL:http://httpd.apache.org/userslist.html for more info.
To unsubscribe, e-mail: [EMAIL PROTECTED]
  from the digest: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: [EMAIL PROTECTED] Troubles w/mod_rewrite

2006-01-19 Thread Jason Williard
I added the RewriteLog directive to the .htaccess file and am now getting
Internal Error messages.  When looking at the error logs, I get:

[Thu Jan 19 13:20:08 2006] [alert] [client x.x.x.x]
/www/vhosts/domain.com/weather/.htaccess: RewriteLog not allowed here

The entry in the .htaccess file looks like:
RewriteLog logs/rewrite.log


Any ideas why this may be happening?
 

Thank You,
Jason Williard



On 1/19/06, Jason Williard [EMAIL PROTECTED] wrote:
 I have a site that shows weather forecasts.  I would like create a
 RewriteRule to redirect to the proper URL when someone appends their
zipcode
 to the base url.

 i.e. http://weather.domain.com/12345 -
 http://www.domain.com/cgi-bin/weather/weather.pl?zip=12345

 So far, I have tried several methods but cannot get it to work.  Here are
my
 current rules in the .htaccess file:

 RewriteEngine   On
 RewriteRule ^/([^/]*)
 http://www.domain.com/cgi-bin/weather/weather.pl?zip=$1 [PT,QSA]

 I have also tried each of the following:

 RewriteRule ^/([^/][0-9])
 http://www.searching.com/cgi-bin/weather/weather.pl?zip=$1 [PT,QSA]
 RewriteRule ^/([^/][0-9]{5})
 http://www.searching.com/cgi-bin/weather/weather.pl?zip=$1 [PT,QSA]
 RewriteRule ^/([0-9]{5})
 http://www.searching.com/cgi-bin/weather/weather.pl?zip=$1 [PT,QSA]
 RewriteRule ^/([0-9])
 http://www.searching.com/cgi-bin/weather/weather.pl?zip=$1 [PT,QSA]

 None of these have worked.  I simply get a 404 Not Found error.  However,
I
 know that mod_rewrite is working as I had another rule in place for
 redirecting anything that goes to that page to the default URL.

 Any ideas?

Use the RewriteLog to see what mod_rewrite is doing.

Joshua.

-
The official User-To-User support forum of the Apache HTTP Server Project.
See URL:http://httpd.apache.org/userslist.html for more info.
To unsubscribe, e-mail: [EMAIL PROTECTED]
  from the digest: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


-
The official User-To-User support forum of the Apache HTTP Server Project.
See URL:http://httpd.apache.org/userslist.html for more info.
To unsubscribe, e-mail: [EMAIL PROTECTED]
  from the digest: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: [EMAIL PROTECTED] Apache 2.0 or 2.2

2006-01-04 Thread Jason Williard
The servers will serve two purposes.  

1) Serving current applications designed for Apache 1.3 (ergo that version).
Some new development will take place in the area, but mostly in the form of
upgrading and enhancing current applications.

2) Serving new applications designed around the latest technologies.  These
sites will start out in beta and eventually move into production.

So the real question is this... Assuming we development begins today on a
new application, would it be safe to work with the 2.2 branch, or are there
still too many bugs as well as a lack of supporting technologies to make
that a good choice? 
 

Thank You,
Jason Williard


-Original Message-
From: Steven Pierce [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, January 04, 2006 9:16 PM
To: users@httpd.apache.org
Subject: Re: [EMAIL PROTECTED] Apache 2.0 or 2.2




*** REPLY SEPARATOR  ***

On 1/4/2006 at 9:01 PM Jason Williard wrote:

I am building a set of web servers that will be running both Apache 1.3.x
and a version of the 2.x branches.  My question is quite simple... Which
version is recommended?  Is the 2.2 branch stable enough and supported
enough or should I install 2.0 for the time being and upgrade to 2.2 in the
future?

The answer would be what are you trying to do??  What other applications are
you
running, are you going to use something that is only support by 1.3 or are
you 
using something that is supported by 2.x also?  

Why run two copies?  I would pick a flavor and run it.  


-
The official User-To-User support forum of the Apache HTTP Server Project.
See URL:http://httpd.apache.org/userslist.html for more info.
To unsubscribe, e-mail: [EMAIL PROTECTED]
  from the digest: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


-
The official User-To-User support forum of the Apache HTTP Server Project.
See URL:http://httpd.apache.org/userslist.html for more info.
To unsubscribe, e-mail: [EMAIL PROTECTED]
  from the digest: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]