Tag Info

New answers tagged

0

I haven't found a way to put in a rewrite rule that puts all your virtual hosts into maintenance mode. Here are some other possible approaches: From How to disable all apache virtual hosts?, Vinko Vrsalovic suggests using a single command to disable all your virtual hosts: find /etc/apache2/sites-enabled/ -type l -exec rm -i "{}" \; You would then ...


1

The easiest way is to modify your hosts file to hardcode the domain name to the new IP address temporarily. See this guide for OS-specific instructions. Don't forget to remove the entry again after you're done testing. Alternatively, you could setup a temporary test subdomain for each site on the new server (test.example.com), set it up as an alias, and use ...


1

Unfortunately, with WordPress you will not be able to know which plugin is consuming resources. You will have to disable the plugins one by one and then try. You can even optimize the database so that it does not consumes much resources. It may be helpful to indicate which hosting plan you have with GoDaddy.


1

Postfix has the feature always_bcc. This parameter specifies an optional address that receives a copy of each message that enters the Postfix system, not including bounces that are generated locally. Here is a link: http://www.postfix.org/postconf.5.html Search for always_bcc. This should offer some clue as to what Postfix is doing and if it is working, ...


1

The 403 Forbidden error is due to the access denied issue as intended, there is no issue here - that seems fine. The 404 Page Not Found error is due to your .htaccess file looking for and not finding where it expects, some kind of customised error page to show in this circumstance. It's possible your hosting provider may have this configured at the ...


1

The way which I hide that type of issue is by using .htaccess, and it actually works mighty well. The code comes from my webhost, and you have to make some slight edits to fix it up to work, but it should work for you also. # .htaccess main domain to subdirectory redirect # Do not change this line. RewriteEngine on # Change example.com to be your main ...


0

Your "Method 2" looks appropriate to me to match http://www.testdomain.com/john/2/doe. Only, you may want to try to add the RewriteBase / too, something like this: RewriteEngine On RewriteBase / RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule ^([^/]+)/([^/]+)/(.*)$ test.php?name=$1&id=$2&nick=$3 [L,QSA] Instead ...


0

I had a similar rule, try this one: RewriteEngine On RewriteBase / RewriteRule ^test/([A-Za-z0-9-]+)/([0-9]+)/([A-Za-z0-9-]+)/?$ test.php?name=$1&id=$2&nick=$3 Your links should be: test.php?name=john&id=2&nick=doe


3

You mentioned that two options are valid for you, so I'm using the second one, http://www.testdomain.com/john/2/doe, and assuming a clean .htaccess RewriteEngine On # RewriteCond %{REQUEST_FILENAME} !-f # RewriteCond %{REQUEST_FILENAME} !-d RewriteCond %{QUERY_STRING} ^name=([\w]+)\&id=([\d]{1,3})\&nick=([\w]+)$ RewriteRule .* /%1/%2/%3? [R=301,L] ...


0

You need to have a web server running at www.domain.com:81, and create a .htaccess file there.


0

On domain.com:81 create .htaccess file (where site/ is): RewriteEngine on RewriteRule (.*) http://domain.com:80/$1 [P,L] With this when you go to domain.com:81 the site will proxy to domain.com.


3

Simple answer. Hosts provide what is asked for and works best. It is a double-sided coin. Apache has been extremely successful and is stable and seasoned code therefore hosts don't have to work hard to support it. As you may know, Apache is one of the first successful web servers and serves the vast majority of web installations therefore it is asked for the ...


0

Best way to do this is not from your .conf file. Do this: .htaccess example: RewriteEngine on RewriteCond %{REMOTE_ADDR} !^192\.168\.1\.1 #Replace with IP address you wish to allow RewriteRule .* http://www.yourwebsite.com [R=301,L] #Replace webaddress with yours Make this file in the directories you are trying to keep people out of. Then ...



Top 50 recent answers are included