Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
05-31-2010, 03:36 AM #1
- Join Date
- Sep 2006
- Thanked 0 Times in 0 Posts
mailto link displaying "localhost" when used from htaccess file
I was hoping to hide my mailto links in the htaccess file and it seemed to be working perfectly however I figured out today it's doing something weird. When you hit on the email link, the email address in the to box is email@example.com/
It appends this weird "localhost/" to the end of the email address and I have no clue why! My option to get around it is to redirect to a PHP file that headers to the mailto link but I was hoping to keep it in my htaccess and nice and tidy.
RewriteRule ^contact/email$ mailto:firstname.lastname@example.org [L]
07-07-2010, 11:13 AM #2
- Join Date
- Mar 2010
- Virginia, USA
- Thanked 5 Times in 5 Posts
Odd - Not sure where to start with this one. I setup the same rewrite rule on my domain and I'm not getting the behavior you are experiencing. Try it out and let me know what it does for you.
If you still get the appended localhost - it is likely something occurring on your local network/computer. If you don't then it's a setting somewhere on the server.
I assume that a mailto link hard-coded in HTML served from your server doesn't append the locahost text? It sounds like that's what you are doing with the PHP file.