The Apache HTTP Server is an Open Source Web server, which originated from a series of patches to the NCSA HTTPd. Apache is the world's most popular Web server, which is run on 54.90% of all Web servers according to the Netcraft survey conducted July 2010.

learn more… | top users | synonyms (1)

2
votes
1answer
259 views

Upgrading Apache 2.2 to Apache 2.4 [closed]

I'm planning to upgrade Apache 2.2 running on my centOS 6.5 server to Apache 2.4, Does the new Apache version worth the update?
2
votes
1answer
58 views

Rewrite one URL to another, and then block the first one using Apache mod_rewrite

Description: I've changed with RewriteRules (no redirect) a typical PHP-like URL: domain.com/script.php?parameter=value to more friendly one: domain.com/script/value But I still can reach the ...
2
votes
1answer
551 views

What are the most commonly used and basic Apache htaccess redirects?

This question is here so we can offer users who are looking for information on how to make one or more common or basic redirects in Apache using the htaccess file. All future questions pertaining to ...
2
votes
1answer
53 views

Handling APACHE file caching

I have used .htaccess to cache images, css and javascript files on my server for up to a month. My problem is that some users get updates that I made recently and all works normally while some user ...
2
votes
2answers
640 views

Is it possible to count the number of hits or loads of a webpage without anything fancy?

I know very little, but I do know that I have some server space given by my University with a file called public_html which anyone can load html and other files from. So is there a simple way to add ...
2
votes
1answer
55 views

How should I set the default virtualhost?

I want to run 2 websites. One for www.example.com, and the other for everything else (www.example2.com, www.example3.com) How I do it? I tried: <virtualhost *:80> ServerName www.example.com ...
2
votes
1answer
548 views

How to log username in Apache logs?

I need some help regarding how to log the user-name into apache logs. I'm building a use-case for Security Information Event Management. Is the method the same in case of IIS or just applicable to ...
2
votes
1answer
383 views

How do I use htaccess to make a short URL to a MediaWiki page?

I'd like to rewrite /liam to /index.php/Liam_Edwards-Playne. I've currently written this below in the appropriate .htaccess file but it is still returning a 404: RewriteEngine On RewriteRule ^/liam$ ...
2
votes
1answer
1k views

Tomcat serving static content with directory listings

I have Tomcat 7 configured to serve static contents from a directory: <Host appBase="webapps" name="localhost"> ... <Context docBase="/var/projectA/static" path="/projectA/" /> ...
2
votes
1answer
227 views

Apache2 Unwantingly Allowing Proxy Requests

I'm not sure if this is the right location, but this is fairly urgent. I have completely removed all traces of mod_proxy and the other mod_proxy mods, although the Apache server continues to allow ...
2
votes
1answer
2k views

Help with 301 redirect from subdomain to root domain

I need to forward existing subdomain links to the root domain as the subdomain no longer exists. I have tried so many different lines of code in my .htaccess file and can not get the redirect to work. ...
2
votes
2answers
673 views

getting 500 intenal error when setting 301 redirect using .htaccess

I am trying to use a 301 redirect to direct users and bots to my new site but when I put the .htaccess live i keep getting a 500 internal error shown. The site is actually a subdomain which i want ...
2
votes
3answers
893 views

Under an Xampp install, I modify the apache httpd-vhosts.conf file and then my Apache server will not start

I have read all the articles but still must be doing something wrong... I modified the httpd-vhosts.conf file to access the project I am working on... I have tried many different configurations and ...
2
votes
1answer
74 views

Handling request after installing MAMP (no DNS setup yet)

I've just installed MAMP on my mac machine and checked the server is working by looking at localhost. I looked up my IP address by ifconfig. When I use another machine, I still can't get connected to ...
2
votes
1answer
1k views

When is the leading slash (/) needed in mod_rewrite patterns?

Here is an example from the Apache documentation for enforcing canonical hostnames: RewriteCond %{HTTP_HOST} !^www\.example\.com [NC] RewriteCond %{HTTP_HOST} !^$ RewriteRule ^/?(.*) ...
2
votes
2answers
469 views

Notification for too many Apache connection errors on shared hosting?

My hosting provider specifies how many simultaneous connections the hosting account can handle. The question is how do I know if my site reached this limit and drops connnections? I have a PHP site ...
2
votes
1answer
131 views

Is it possible to check the case on Apache redirects or aliases?

I have a big website (15,000 pages) with a log list of redirects (about 800) that have been used in marketing pieces for years. My Apache server has been running mod_rewrite for the past 10 years or ...
2
votes
2answers
618 views

Nginx frontend, Apache backend, and Magento

I've got a Magento installation, which works perfectly from a customer's point of view. However, when you try and do batch tasks with the admin, Nginx often closes the connection to the browser early, ...
2
votes
2answers
2k views

Is it possible to force a directory index to display even if an index file exists?

On my Apache server I need to display a directory index of a given folder even if it already contains an index file that has been defined in DirectoryIndex. In this case an index.html file exists, but ...
2
votes
2answers
173 views

Apache2: Deny access for mail.mydomain.com but allow www.mydomain.com, both points same ip

i have a linux mail+http server located throguh Internet at www.mydomain.com. Domain was bought at GoDaddy so after configuring the server and getting the public ip address i went at GoDaddy's profile ...
2
votes
1answer
461 views

Virtual Host under MacOSX not working

I have setup a virtualhost for MacOSX Apache installation. These are my steps: edit /private/etc/apache2/httpd.conf removing comment from: Include /private/etc/apache2/extra/httpd-vhosts.conf ...
2
votes
1answer
372 views

Restrict SSL access for some paths on a apache2 server

I wanted to allow access to www.mydomain.com/login through ssl only. E.g.: Whenever someone accessed http://www.mydomain.com/login, I wanted him to be redirect to https://www.mydomain.com/login so ...
2
votes
1answer
1k views

Accessing server stats using PHP

There are over 10 stats packages installed in my server (AWStat, Webalizer, etc) and cPanel has an interface to show them in terms of visitors, bandwidth, popular pages, etc. It is possible to access ...
2
votes
1answer
3k views

Getting 403 Forbidden after changing webroot

I am running Ubuntu with Apache (LAMP stack). When I changed the webroot from /var/www to /media/data/www, I keep getting 403 Forbidden even after chmod-ing the directory + files to 777. What did I do ...
2
votes
1answer
1k views

How do I save user uploaded files outside of the web folder but use them on my page?

I have read that one of the best things to do for security with user uploaded files is to store them outside of the web folder, as there is very little you can do to ensure that that jpg image the ...
2
votes
3answers
938 views

Why is a # sign added to the end of URLS?

Note: I'm asking this from the perspective of the site developers (trying to help someone there). not as a user. Please don't forward this to superuser.com. It's a server admin question. Have a look ...
2
votes
2answers
442 views

Removing the script extension with URL rewriting on Apache

Given a (slightly theoretical) physical disk layout of: \products\cameras\50d.jpg \products\cameras\20d.jpg \products\lenses\18-55.jpg \products\lenses\28-135.jpg \products.php At the moment, I've ...
2
votes
1answer
61 views

Simplest way to lock down a beta web site but allow paypal payments

Perhaps a strange question, but I have a website that's not ready for production use online in order to test paypal payments. I had locked down the site using a .htaccess file however this also ...
2
votes
2answers
62 views

Need help writing .htaccess / Apache rule

I have some URLs which are now 404 due to site upgrade. I want all URLs starting with www.example.com/archives/* to point to www.example.com/news (notice that after archives there is a wildcard ...
2
votes
1answer
92 views

How should I set up and use a CDN for my web application?

I plan to create and run my own CDN. Currently, media and other static content is being served by the web-servers which are behind a load balancer which is a waste of resources. The network structure ...
2
votes
3answers
82 views

Different authentication for HTTP POST and GET requests in Apache

I want to authenticate for POST requests for http://path/to/logical/abc.xml (but not GET requests to that URL). How do I put constraints like this in place? The paths are logical and location ...
2
votes
1answer
149 views

Restricting post method and authentication to specifc URL paths in Apache .htaccess

I shall start with an example. I want to restrict to POST requests only for http://path/to/logical/abc.xml and restrict to GET only for http://path/to/logical/def.xml. How do I put constraints like ...
2
votes
1answer
61 views

Sendmail encrypted

I manage a website running on Apache. It has public and private areas. When people apply for an account to access the protected portions of the site, they do a TLS/SSL protected POST containing their ...
2
votes
1answer
90 views

Go up one directory in mod_rewrite

I've got a standard Zend Framework 1 project that looks a bit like this: Project |- public |- .htaccess |- index.php The .htaccess looks like this: RewriteEngine On RewriteBase / RewriteRule ...
2
votes
1answer
305 views

Apache - directory browsing gives 404

With no .htaccess files and Options FollowSymLinks MultiViews Indexes followed by AllowOverride None in the vhost configuration, I'm getting 404 responses from directory listings. Are there some ...
2
votes
1answer
72 views

Configuring an Apache server to run Python

I currently have a website set up on an Apache server running on Redhat Linux, and am trying to configure it to be able to run Python scripts. Essentially, I want to allow Python to be executable, so ...
2
votes
1answer
213 views

Managing Xampp on USB for Mac and Windows machines

I am working on some PHP projects (Wordpress mostly) with MySQL databases and primarily use my Windows Desktop to do the work on whilst running Xampp. This all works great until I need to take my ...
2
votes
1answer
93 views

Where does Apache get the 'last modifed' date for its automatic indexes?

I have a Solaris server running Apache, and I am using the following .htaccess to generate automatic indexes. Options +Indexes # SET INDEX OPTIONS IndexOptions +NameWidth=* Where does the "Last ...
2
votes
1answer
2k views

How can I force a VirtualHost in Apache to not listen for undefined subdomains on 443?

In /etc/apache2/sites-available/example.com: <VirtualHost *:443> ServerName www.example.com DocumentRoot /var/www/example.com/htdocs SSLEngine on ...
2
votes
1answer
134 views

Show Cloudflare requests in apache log

I have a number of sites using cloudflare as a CDN with the apache mod_cloudflare installed to restore original visitor IPs to my server logs. Does anyone know of a way I can make the logs identify ...
2
votes
3answers
4k views

How to Change the www root directory on WampServer

How can i change the root directory of the currently installed wampserver to some other directory.
2
votes
1answer
82 views

Setting up multiple domains on one Cpanel account

I set up an account on Cpanel for a domain "abc.com". However, if I wanted to point the A record for "def.com" to abc's existing account, what changes would I have to make server side? I'm aware that ...
2
votes
1answer
165 views

mod rewrite doesn't work when i added multiple domains

i have redhat linux server and i was using /var/www/html to display my site. By using the following directive rewrite mod was working fine. <IfModule mod_rewrite.c> # Enable mod_rewrite ...
2
votes
1answer
114 views

How to find data usage of a user on my website?

I have a website (project) where users get logged in, do their work and then they log out. I need to build a report that displays how much each person has used of data. (bandwidth, how much was ...
2
votes
1answer
190 views

Internal CDN and setting up subdomain to increase maximum parallel connections

I've heard that browsers can have around maximum of 6 parallel connections per domain at a time. So I decided to have another subdomain "cdn." then use mod_rewrite to point to media folder then ...
2
votes
1answer
153 views

how to fix .htaccess - redirect http://408.111.1111.domain.us/ to http://domain.us/index.php?w=408.111.1111

We want to use mod_rewrite and .htaccess to do a redirect. How do we redirect http://408.111.1111.domain.us/ and www.408.111.1111.domain.us/ to http://domain.us/index.php?w=408.111.1111 ? If the ...
2
votes
1answer
79 views

CDN for site with target market in Australia

I was told that http://www.edgecast.com/ is very good CDN provider for Australian market. I have a cloud server based in Sydney Australia but was wondering whether it's even worth getting cdn as my ...
2
votes
1answer
5k views

Enable 'mod_rewrite' Using .htaccess File On cPanel Shared Hosting Server

I'm using cPanel to host my website. I need to enable 'mod_rewrite' on this Shared Hosting cPanel account to run my script. I've tried to Google the solutions high and low but did not find any luck ...
2
votes
1answer
340 views

Apache rewrite rule that matches a specific query string

I need to rewrite a specific wordpress url to a 404 error: ?page_id=15 => 404 How can I match the query string? Apparently Apache doesn't feed that to the rewrite mod...
2
votes
1answer
143 views

http request terminating early

I noticed that on some of my sites, images were occasionally not getting downloaded fully. After a bit of investigation it appears that it is not restricted to images - .css, .js etc were also ...