apache

is restarting apache service needed with any changes to rewritemap file?

I am using a perl script file as a map file in RewriteMap directive. As i read the apache load the script once at the beginning, So is it needed to reload or restart apache after any changes to this script file? ...

Apache module in C: how to write data to client socket?

Hello, I have created a simple mod_perl module, which writes a 0-terminated string to the Flash-clients connecting to the port 843. It works ok, but uses 20m per httpd-child at my CentOS 5 Linux machine. So I'm trying to rewrite my module in C, but I'm not sure how to access the client socket through the conn_rec struct that my protoco...

How can i put my WAMP online for someone to access?

I would like to briefly open up my computer and allow my business partener to see what I've been developing on the my localhost. I understand there are probably some security issues with this but I only want to open up my computer for a few minutes... What do i need to setup on the following interfaces to do this? my wireless router w...

Setting an apache reverse proxy as a gateway between client cert authentication (mod_ssl) and basic authentication for backend server

Hi, I have a backend server that expects a Basic HTTP Authentication. I can't touch this server and its authentication mode. But, I'd like to replace this authentication by a client certificate on a reverse proxy in front of this server. This would make something like this : User --(ssl auth)--> ReverseProxy ---(Basic Auth with login)...

Redirect not working for complex rewrite rules (.htaccess)

Hello, I'm trying to make a redirect from a non-www version of the link to the www one. Its working fine for something like http://mywebsite.com but it fails for a request like http://mywebsite.com/artists/metallica/ or even a complex one. The whole .htaccess file is bellow. Any clues? Options +FollowSymLinks RewriteEngine On Rewrite...

Cannot change php session cookie name

I copied an existing and successfully running site to a new development server. The login on the new server is now broken, and I tracked it down to the fact that although the session cookie is renamed ... ini_set('session.name', 'DOMAIN1'); ... the browser keeps storing the sesssion cookie as PHPSESSID. When I remove the above line...

How to make this mod rewrite

This drives me crazy, it should be easy but I can't... I need to rewrite URLs like this ones: www.domain.com/foo/bar/more/evenmore.htm www.domain.com/foo/bar/more.htm www.domain.com/foo/bar.htm www.domain.com/foo.htm into: www.domain.com/?var1=foo&var2=bar&var3=more&var4=evenmore www.domain.com/?var1=foo&var2=bar&var3=more www.domai...

Issue with Passenger - Apache

Hi, Running in a Linode slice with Ubuntu 10.04 LTS. I am getting a 500 Internal Server Error. The Apache log has: Apache/2.2.14 (Ubuntu) Phusion_Passenger/2.2.7 configured -- resuming normal operations caught SIGTERM, shutting down * Passenger could not be initialized because of this error: The Passenger spawn server script, '/usr/...

Apache wildcard at domain level

Hi, I have few sites, and they all have identical setup on a single server. Now, instead of the separate configuration file for each of them in sites-enabled directory, I want to have a common file. Idea is this: www.abc.com should have /var/www/abc as DocumentRoot, www.xyz.com should have /var/www/xyz as DocumentRoot, etc. Al...

how do i block people from outside by web server from seing what technologies im using such as apache and/or php?

i am running a test server locally that is also broadcasted (for education purposed) on a mac and i ran a software called acunetix (www.acunetix.com) and from another computer and it was able to detect the technologies used on the server. how can i block anything from viewing this information? ...

How to modify .htaccess for web app (in combination with WordPress 3.0.1)

My question is about .htaccess I am using WordPress 3.0.1 as the front end of my web application. I want most HTTP accesses to follow the normal WordPress flow. However, I have created a special "Page" in WordPress that has embedded PHP code that powers my web app. URL's of this form "http://site.com/app/" already go to the correct pa...

[PHP] Detect if script in Domain Root or Subdirectory

Hi, I have written a small php script which uses clean urls for which mod_rewrite rules are used. that script needs to know where is located in order to run. root domain : yourdomain.com sub dir yourdomain.com/subdir/ Currently to set path for the script. I use following two, Case: root domain: define("ScriptURl",'http://'.$_SE...

How do I configure PHP + Apache on Amazon EC2?

I am new to this of course. I am trying to configure PHP and Apache on a new Amazon EC2 AMI. This is a very lightweight server so the Micro instance fits the bill. I just need Apache PHP I ran sudo yam install apache2 sudo yam install php I copied info.php to /var/www/html info.php only contains <? phpinfo(); ?> when i brow...

How to combine RESTful calls and Apache wink?

Hi, everyone, I have a question about the REST and Apache wink. I want to use the Apache Wink to handle the transition between front end and back end. However, I don't have any ideas on how to start and learn it. Can anyone help me? thank you. ...

Apache RewriteRule removing submit x y coordinates from Querystring (Mac Snow Leopard OS X)

This ought to be a simple exercise in Apache with mod_rewrite and all of it's flexibility. I have verified the Rewrite module is working with full logging but no matter how I shake out my rules and conditions, I can't get it to work. What I want is to rewrite the following url: http://www.domain.com/search?x=10&amp;y=10&amp;query=sear...

Save cookies with subDomain ?

greetings all i want to save cookies with subDomains and i want to know how to do so this is my current configuration: ProxyPass / ajp://127.0.0.1:8009/appName/ ProxyPassReverse / ajp://127.0.0.1:8009/appName/ ProxyPassReverseCookieDomain .appName.com *.appName.com ProxyPassReverseCookiePath / /appName ...

which is best, either fetching from another PHP file or from mysql db in PHP?

i have a module called online events in my website, this module will run for every 8 sec and fetches a recent activities in my websites. So, if more than 100 users are using my website at a time, it consumes more memory and more cpu usuage. what should i do to reduce cpu usage and memory, provided it should not affect a online events mod...

How would I write a RewriteRule to make redirection

I want to rewrite the html and xml files and directories to the pagename query string using .htaccess file. like this : mysubsite/category_1/category_2/ mysubsite/category_1/category_2/file1.html mysubsite/category_1/category_2/file2.152.html index.php?pagename=category_1/category_2/ index.php?pagename=category_1/category_2/file1.html ...

Is it good to cache the Zend application.ini file to make my application run faster?

If I remember correctly, parsing .ini files in PHP takes a long time. So, why not cache it (the file won't change during a request) What is the best way to do this? Or are there any reasons not to do it? ...

Apache httpclient returning page before it loads?

I noticed a strange phenomenon when using the apache httpclient libraries and I want to know why it occurs. I created some sample code to demonstrate. Consider the following code: //Example URL String url = "http://rads.stackoverflow.com/amzn/click/05961580"; GetMethod get = new GetMethod(url); HttpMethodRetryHandler httpHandler = ne...