473,788 Members | 2,882 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

.htacess ErrorDocument 404 and php

Hi,

I have the strangest error with my .htaccess.

I have something like
ErrorDocument 404 /error/error.php?err=4 04

But that does not work for php file?

If I look for www.example/test.html, (<= test.html does not exist), then the
error.php file gets loaded, but if I look for www.example/test.php, (also
does not exist) then the standard 404 page gets loaded.

Any reason why that would happen?

Sims
Jul 17 '05 #1
0 1767

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
1946
by: Giobibo | last post by:
I have in writte a simpy .htacces file with the only line: ErrorDocument 404 /my404.php thus if type in the address line of my browser a missing page like: notexistpage.html I get correctly my404.php as error page, but if I type in the address bar of the browser the page:
7
2275
by: Günther Steinmetz | last post by:
i think it is user friendly to have a default file in each subdirectory. However, i hate to have lots of index.html files. Instead i would like to have a meaningful and unique file name for all my default files. Is there any way to specify the default file name for a given subdirectory locally (i.e. not on the server)? Thanks for any answers. Guenther
1
4361
by: treelife | last post by:
I'm getting and internal server error when | run the following mod_python script. I am actually trying to run Django. Script: from mod_python import apache def handler(req): req.content_type = 'text/plain' req.write("Under Construction")
4
6970
by: liyanage | last post by:
I recently worked on error handling and three related issues/questions came up. 1.) I am trying to trigger Apache ErrorDocument handlers by setting appropriate HTTP status codes in my PHP code, but I don't get the expected results. My PHP file:
0
1347
by: botho.willer | last post by:
Hello! Some time ago I discovered a script on php.net that uses a fopen handle on a .htaccess-protected directory to check the authorization of a user. The crucial Code is this: $handle = fopen("http://username:pw@domain.com/directory", "r"); (of course the username and password are variables entered by the user) I used this script to protect a admin-area for some time without any
1
1717
by: Sean128 | last post by:
Hi, I hope someone can help me - this seems like it should be a really simple problem but I've been having trouble trying to solve it all week. I have hosted my website on a Linux server in 1 and 1 that I can not modefiy the Apache server. They told me I need to create the .htaccess file. The code that I put in my Biocon folder in my .htaccess file is: php_value include_path "/bioconstore/lib:/plate-latest"
0
2850
by: kokababu | last post by:
Hi I have set my httpd.conf in the following way, my reverse proxy is working but ErrorDocument is not working. It is Apache HTTP server 2.x ***SAMPLE**** <VirtualHost *> ServerName www.realDomain.com ServerAlias www.fakeDomain.com
27
4834
by: parashar123 | last post by:
There are two pl files: realtimechart.pl and realtimedemo.pl realtimechart generates a realtime graph which would an image file(png,gif,jpeg etc) and realtimedemo generates a html file alongwith the graph produced by realtimechart and also refreshes it using the image id. But somehow it is not taking the chart generated from realtimechart.pl. There is some problem in this statement <img id="ChartImage1" src=...
1
1424
by: Jason7899 | last post by:
hi, i have this domain for example: mydomain.com and i want when i enter this url in browser: mydomain.com/test the htacess see the "test" redirect the site for test location and to that for the other words that i enter after "/" for the folders that exist in server the htacess will don´t do nothing the objective is only for the words what i want
0
9656
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
10366
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
10112
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9969
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
8993
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7518
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6750
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5536
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
3
2894
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.