apache

Apache redirect

Hi, I would like to redirect a URL using RedirectMatch within Apache eg, /test/one/?? redirect to /test/two/?? where the ?? represents any string that follows The redirect i'm using below does a straight redirect but doesnt match any string after... RedirectMatch Permanent ^/test/one?$ /test/two/ Thanks alot ...

Query about Apache (httpd) dumpio log entry for the Request body which is coming NULL on Tomcat side

Hi, I am working on a hosted application running on Apache Tomcat 6.0.18 and it is hidden behind Apache (httpd). They are connected through mod_jk. We have take VPS and therefore Apache has been hosted as VirtualHost. The OS is CentOS 32 bit. The problem is that very randomly Tomcat is getting NULL request (it may have some URL specifi...

Why is $_POST empty in PHP5 under Apache?

In the file http://example.com/path/foo.php, I have the form (formatting deleted): <form action="/path/foo.php" method="post"> Email: <input type="text" name="email"> Password: <input type="password" name="password"> <input type="checkbox" name="remember" checked="checked"> Remember me <input type="submit" value="Log In"> </form> Some...

Apache proxy Cluster redirect.

I have a apache httpd which distributes the load between 2 servers (Serv_A and Ser_B). Using sticky session. If the request was sticky with Serv_A and Serv_A goes down. Question is? 1. should the proxy send the request to Serv_B without doing a redirect from the browser? OR 2. it should always redirect from the client browser to Serv_...

Apache Felix Bundle Repository - Calling from another bundle

I have a simple test program which is designed to consume the Apache Felix Bundle Repository bundle service however I am having trouble configuring it through eclipse. I am using the jar for the bundle (org.apache.felix.bundlerepository-1.4.0.jar) as an referenced library and have added it to the classpath in the manifest. When I try t...

Simple rewrite rule for a nginx + apache2 with mod_wsgi

Hi guys, I'm stuck with this, my skills in the web servers area are poor... I have an Nginx acting as a proxy for an Apache2 running with mod_wsgi and mod_rewrite. What I want to do is rewrite every URL from www.example.com to example.com, i.e. stripping the www part from each URL request before serving. This is the layout of the differ...

Mod_Rewrite Question

Hello, I'm trying to forward example.com/signup and example.com/signup/ (with trailing slash) to example.com/signup.php I wrote following to .htaccess and it works for example.com/signup/ but doesn't work without trailing slash... How can I solve the problem? RewriteEngine On RewriteRule ^question/(.*)-(.*) /question.php?qid=$1 Rewrit...

How to detect mod_rewrite without apache_get_modules()?

Is it possible to detect mod_rewrite in PHP when function apache_get_modules() is not available? ...

Match all subdomains except one in mod_rewrite

Ok, so I'm doing a mod_rewrite, and I'm in a situation to where I need to match any subdomain except for one. It starts out looking like this. RewriteCond %{HTTP_HOST} ^([^\.]+)\.example\.com$ [NC] So that matches and captures a single subdomain, no periods. But let's say I don't want to match the submdomain named 'dog'. I tried to do...

Apache FOP: Displaying UTF-8 Characters in PDF (without embed?)

Hi, I'm trying to use FOP to export a PDF with UTF-8 characters, preferably without needing to embed the font. The following code: <fo:block font="10pt Helvetica" text-align="justify" space-after="10pt" space-before="8pt" keep-with-previous="auto" keep-together.within-page="auto"> <fo:block font-weight="bold" color="gray">Summary</fo...

URL Rewrite to exclude existing directories

I'm trying to redirect URLs from example.net/customname or example.net/customname/ to example.net/my/home.php?username=customname . This in itself is not complicated: RewriteRule ^([a-zA-Z0-9_-]+)$ my/home.php?username=$1 RewriteRule ^([a-zA-Z0-9_-]+)/$ my/home.php?username=$1 However, I want to exclude my existing directories and fi...

mod_rewrite ecommerce URL design

I have problems with how I should structure my product listing pages, products pages, webpages. It roughly translate into this: /bags/nicebag.html = /product.php?product=nicebag&category=bags /nicebag.html = /product.php?product=nice_bag /bags = productlisting.php?&category=bags Problem is that webpages will share same URL structure...

Suppressing / controlling logging in org.apache.xmlrpc.XmlRpcClient?

I have inherited some Java code that does some testing of our XMLRPC server. So far so good. Part of that code deals with stopping the server (a few repetitions of "check if server still there and if so send it command to shut down"). As the server is shutting down, some of these "is the server still there?" and/or "tell it to shut dow...

apache2 and mysqldump causing massive load average spike

I've got a problem that's causing me some headaches and I could use some ideas on how to investigate/fix it. Setup: I'm running a Rails app (Apache2 w/ Passenger) on server A (Rails.A) I'm running the master DB on a dedicated DB server B (DB.B) I'm running a slave DB on server A (DB.A) with standard MySQL replication (just for backup ...

How Do I Serve a File Through JSMin PHP Script With Correct HTTP Caching (using .htaccess?)

I'm using the PHP script for JSMin to remove comments and whitespace from my javascript and css files before serving. If I set <script src="jsmin.php?file=myfile.js"> the file is not ever cached, since the Last-Modified HTTP header is never checked for a script. So in order to run the files through JSMin and (hopefully) enable cach...

.htaccess Apache on cPanel only working in some cases

Hey there SO, I'm using the Zend Framework, so I'm bootstrapping into a file called index.php. Naturally, I don't want images to be bootstrapped, so I've added a .htaccess file. Here's what it looks like /application /library /public (this is the root of the site) /images /js .htaccess index.php This is what's w...

What's wrong with this mod_rewrite rule?

Can anyone spot what is wrong with this URL rewrite? I can't get it to pass anything to GET (the script loads, but no parameters are passed): RewriteRule ^archive(/(.*))?$ archive.php?action=$1 [QSA,L] I want to map "archive/browse/" to "archive.php?action=browse". ...

Apache mod-rewrite folder overwrite

Hello, I have Apache installed with the XAMPP package, and I'm working locally. I have a rule in a .htaccess file that overwrites everything, let's take this for example: RewriteRule ^(.*)$ index.php?x=$1 Note that I do NOT have any RewriteCond that makes this rule ignore existing file or folders. Now let's say I have a folder name...

PHP error_reporting is 0

On my windows laptop I have Apache and PHP so I can develop websites locally. Then recently PHP files stopped reporting errors. In the php.ini file I have set error_reporting = E_ALL & E_STRICT; display_errors = On But it still does not report any errors. If I echo error_reporting() i get 0. What could be causing this problem? ...

view as html feature

can anyone help me how to read .doc and .xsl file on linux server through php like the view as html feature on gmail... ...