The tag has no wiki summary.

learn more… | top users | synonyms

0
votes
1answer
14 views

Redirect from secure site to non-secure site with wildcard subdomain

I have the following set up in apache2.conf: <Directory /var/www/html> RewriteEngine on RewriteCond %{HTTP_HOST} ^(www\.|)mydomain\.com$ RewriteCond %{SERVER_PORT} !^443$ ...
0
votes
1answer
65 views

Cannot set up mod_rewrite with XAMPP

I'm trying to enable mod_rewrite on a XAMPP 5.6.3 installation. I've been following these guides: http://www.leonardaustin.com/blog/technical/enable-mod_rewrite-in-xampp/ ...
0
votes
1answer
10 views

Using Apache RewriteRule

I'm attempting to get a very simple RewriteRule working in Apache - I've set Apache2 up (in Vagrant) and run sudo a2enmod rewrite successfully (and restarted Apache after), with the following trivial ...
0
votes
0answers
88 views

The requested URL /fr/index.php was not found on this server Htaccess issus

I want to delete query string (fr) from my URI with htaccess rules, so I added this rule in the htacces file : RewriteRule ^((?!fr/).*)$ /fr/$1 [L,NC] But apache gives me this error: The requested ...
0
votes
0answers
16 views

mod_rewrite thinks names which are part of filenames are not worth rewriting

I'm trying to rewrite every request which isn't an existing file or directory to end up in a couple of $_GET key-value pairs for dispatcher.php to use. So far, everything seems to work nicely except ...
0
votes
0answers
87 views

Don't reverse-proxy robots.txt

I do not want to reverse-proxy robots.txt. How would I use a RewriteRule to redirect any request to the same robots.txt? For example, I want the RewriteRule to do this: ...
0
votes
0answers
75 views

mod_rewrite folder alias and hide original folder

I have a script in /script folder and I need to hide it from mydomain.com/script and make accessible from mydomain.com/secret . All must work with mod_rewrite (I can't rename the folder script to ...
0
votes
1answer
403 views

Reverse proxy 502 bad gateway

I have setup a subdomain to proxy my plesk panel, but when saving pages I am getting 502 Bad Gateway error instead of a completion message. I am running CentOS 6. Here is my vhost.conf configuration ...
0
votes
1answer
40 views

Redirect domain name

I have two domain names pointing to my server. I want them both to serve identical HTML. I thought I would just do the following, however, it was unsuccessful. Note that I eventually will want ssl ...
0
votes
0answers
98 views

Apache mod rewrite testing tool (no online tools)

I've tested some great RegEx standalone tools and found a couple of mod rewrite online tools, but is there some standalone tools for testing apache mod rewrite definitions? Ideally, I want something ...
0
votes
2answers
45 views

apache mod rewrite - how to determine what file on disk is being hit?

A project that I am newly working on has been around for years, and it has managed to accumulate several hundred rather complex RewriteRules within the Apache conf files. When working with some ...
2
votes
0answers
45 views

Keeping Firefox from adding “.html” to url

I've been messing with .htaccess for a while, and have the following rule: RewriteRule ^(mypage|myotherpage)/?$ main.php?p=$1 [L,QSA] If I enter http://mydomain.com/mypage/, it displays main.php as ...
0
votes
2answers
1k views

The requested URL xxx was not found on this server

I have been tearing my hair on this for hours..please help.. I have been running several websites on localhost for months without a hitch. Unfortunately last week I had do do a fresh instal of ...
1
vote
1answer
252 views

Uploadify with apache authentication

I'm trying to get a webapp working on my server. The app is using uploadify and that is the only part that I now can't get to work. I have a Alias to reach the app : (in /etc/apache2/conf.d/appalias) ...
0
votes
1answer
371 views

How do I write a rewrite rule for a virtual host in Apache?

I have a subversion server that is working fine; however, I bought a tool that requires that the project have a "branches" subdirectory an is case sensitive. The entire repository already has projects ...
0
votes
1answer
183 views

Block all referer request on Apache

I use my Apache server for a B2B application and I want to block all the referer requests like this one : [Tue Aug 13 14:23:05 2013] [error] [client 74.63.192.51] File does not exist: C:/Program ...
0
votes
0answers
49 views

How do I stop a Rewrite Rule from happening on my localhost IP?

I thought this would work but it just takes me to my live site RewriteEngine on RewriteCond %{HTTP_HOST} !^www\.mydomain\.co.uk RewriteCond %{HTTP_HOST} !^127.0.0.1 RewriteRule (.*) ...
1
vote
0answers
228 views

apache rewrite to different domain subfolder without changing the address in browser url

Actually we have 2 sites. Site 1: Desktop version hosted in [http://mysite1.com] , using Apache server Site2: Mobile version of mysite.com is hosted in [http://mobilesites.com/mysite1mobile] , using ...
2
votes
1answer
3k views

Apache2 - Redirecting a subdomain to another URL

I have two subdomains, a.website.com and b.website.com, pointing to the same IP address. I want to redirect b.website.com to a.website.com:8080. I have this in my .htaccess file... RewriteEngine on ...
0
votes
1answer
2k views

Configuring Apache2 to Auto redirect calls to port 80 to port 443

I am running an Ubuntu 12.04 Server-based Apache2 server with SSL. I seem to have my configuration correct to achieve SSL connections over port 443, and at first, I did not even configure the server ...
1
vote
0answers
194 views

mod-rewrite rule not working properly for files in sub directories

I'm using the following rewrite url to get prettier urls: RewriteRule (\d+)/(.+) $2?companyId=$1 [NC,L,B,QSA,NE] The url /invoices.php?companyId=123 can for example be expressed as ...
0
votes
1answer
773 views

.htaccess - subfolder URL Clearing

I don't seem to be able to do the following in my .htaccess I have my script in a subfolder inside my root directory, let's call it "ecommerce", and inside that subfolder I have my .htaccess. Am ...
0
votes
5answers
1k views

.htaccess file mod rewrite in godaddy

i have a problem with .htaccess mod rewite in godaddy server. i have .htaccess file like " # Options Options -Multiviews Options +FollowSymLinks RewriteEngine on RewriteRule ...
1
vote
0answers
101 views

.htaccess Not Working as Expected [closed]

I have a hosted account not linked to any domain at /~me. In this home directory I have a .htaccess file: Options +FollowSymlinks RewriteEngine on RewriteRule 123.html cgi-bin/example.php [nc] ...
1
vote
1answer
73 views

Is there a way to detect regular expression support in a htaccess file?

I use to following rewrite rule to pass the whole url to an php script: RewriteEngine On RewriteCond %{SCRIPT_FILENAME} !-f RewriteCond %{SCRIPT_FILENAME} !-d RewriteRule ^(.*?)$ ...
0
votes
0answers
172 views

mod_rewrite working but php pages not found or not recognized (downloaded instead of executed)

In regard to my first post mod_rewrite problems in sandbox: Mac OSX 10.6.6 Apache/2.2.15 (Unix) mod_ssl/2.2.15 OpenSSL/0.9.8l DAV/2 PHP/5.3.3 I am making progress but... Now the index.php page is not ...
1
vote
0answers
188 views

mod_rewrite problems in sandbox: Mac OSX 10.6.6 Apache/2.2.15 (Unix) mod_ssl/2.2.15 OpenSSL/0.9.8l DAV/2 PHP/5.3.3

greetings earthlings, I develop sites on a mac and have been trying to get mod_rewrite to work unsuccessfully. I have it working at my hosting provider just fine but really need it local to ...
0
votes
1answer
212 views

Url rewrite rule [closed]

How to redirect a page form show.php?id=(15charstring) to show/(15charstring) I tried like this it is doing reverse means it is redirecting /show/(15chars) to show.php?id=(15chars) RewriteEngine on ...
0
votes
1answer
2k views

Apache mod_rewrite working with http but not https

I am configuring an apache server to change URLs from [http://(IP)/users/testuser/test.html] to [http:/(IP)/~testuser/test.html] This works fine, as such RewriteEngine On RewriteRule ...
1
vote
1answer
2k views

htaccess how to redirect if all other rules fail?

htaccess has always given my problems. Every time I think I understand it, htaccess goes against what I just thought I understood. Any help would be GREATLY appreciated. What I want to do with ...
1
vote
1answer
542 views

apache - mod_rewrite + mod_proxy working in staging, not working in production ( [P] option ignored )

I have set up a redirect in my Apache virtual host serving several subdomains - call them a.example.com and b.example.com - serving a ruby on rails app. On my virtualhost config file I have this ...
1
vote
2answers
1k views

FireFox continues to redirect based on outdated httpd.conf rules (other browsers dont)

This is really odd, because it shouldn't be happening at all. When I access wellness.learnitlive.com on FireFox, I see it redirected to: ...
2
votes
1answer
1k views

How to hide the PHP file extension using WampServer and .htacess file?

I just installed WampServer on Windows7 and uncommented mod_rewrite and set AllowOverride to All in the httpd.config file. I created an .htacess file and placed it in the root folder with the ...
1
vote
2answers
393 views

What does this mod_rewrite rule mean? [closed]

For some reason this rule is causing havoc in all subsequent rules (none of theme work). What does it mean exactly? RewriteRule . /index.php [L]
0
votes
2answers
121 views

Redirect all non www visitors to the www [closed]

I keep getting variations of the following answer, and it doesn't work RewriteCond %{HTTP_HOST} !^www.alwaysroaming.com$ RewriteRule ^(.*)$ http://www.alwaysroaming.com/$1 [R=301,L] The reason this ...