httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Robert T Wyatt <robert.wy...@gmail.com>
Subject [users@httpd] htaccess redirect URL fragment problem with Safari browser
Date Tue, 04 Nov 2008 22:36:04 GMT
All,

I'll bet this has been answered, but I haven't found it yet. Please
feel free to point me at the answer if you know where it is.

We are trying to redirect users from URLs of the form:
http://www.utexas.edu/student/registrar/schedules/092/regrules/all.html#acc

to URLs of the form:
http://registrar.utexas.edu/schedules/092/regrules/all.html#acc
(Which is a virtual host on the same Apache 2.2.6 server.)

The characters after # would be the relevant variable that we're
trying to capture and pass through to the server.

We are using .htaccess as follows:
RedirectPermanent /student/registrar/schedules/092/regrules/
http://registrar.utexas.edu/schedules/092/regrules/
(all on one line)

This "works" in most browsers but fails with Safari. I found a
reference suggesting that .htaccess files cannot redirect fragment
URLs because the "#" character indicates a comment. However my reading
of the documentation is "Lines that begin with the hash character "#"
are considered comments, and are ignored." Meaning that only lines
beginning with that character are ignored and specifically not meaning
that the occurrence of the "#" character in the middle of the line
indicates the beginning of a comment and will be ignored.

What I don't know is whether I'm on the right track or barking up the
wrong tree. I'm trying to figure out:
1) whether I can achieve what I'm trying to do
2) where the problem is

It's possible that we simply need to add the "all.html" to the
redirect directive; please let me know if you feel this is the case.

Thanks for all pointers,
Robert Wyatt
at UT Austin


---------------------------------------------------------------------
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: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Mime
View raw message