homepage Welcome to WebmasterWorld Guest from 54.167.179.48
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
Become a Pro Member
Home / Forums Index / Code, Content, and Presentation / Apache Web Server
Forum Library, Charter, Moderators: Ocean10000 & incrediBILL & phranque

Apache Web Server Forum

    
unexpected behavior : dir name shows php script?
apache question
observer 24 7

5+ Year Member



 
Msg#: 3266421 posted 7:44 am on Feb 28, 2007 (gmt 0)

I am facing this behavior ...

when i try:

[domain.com...]

its showing me the output of

[domain.com...]

Please note I do not have any dir named delete .

Is this some apache setting somewhere?

Please help.

 

spinnercee

10+ Year Member



 
Msg#: 3266421 posted 1:59 pm on Feb 28, 2007 (gmt 0)

Some browsers try to "fix" simple URLs if they fail:

If you look at your Apache log, you may see the first request for /delete/ which fails, followed by a second request for /delete -- the .php extension may not be needed in the URL if the script is CGI.

This may also have something to do with it:
#
# AddHandler allows you to map certain file extensions to "handlers",
# actions unrelated to filetype. These can be either built into the server
# or added with the Action command (see below)
#
# If you want to use server side includes, or CGI outside
# ScriptAliased directories, uncomment the following lines.
#
# To use CGI scripts:
#
#AddHandler cgi-script .cgi

It's generally bad practice to allow scripts and CGI in the server root [/] for just this reason.

jdMorgan

WebmasterWorld Senior Member jdmorgan us a WebmasterWorld Top Contributor of All Time 10+ Year Member



 
Msg#: 3266421 posted 2:23 pm on Feb 28, 2007 (gmt 0)

Also see Apache mod_negotiation [httpd.apache.org] and AcceptPathInfo [httpd.apache.org] for other configuration options and sources of possible trouble.

Jim

observer 24 7

5+ Year Member



 
Msg#: 3266421 posted 8:08 pm on Feb 28, 2007 (gmt 0)

thanks jdMorgan!

found this: (it tough to search the web when you dont know what option you are searching for. thanks).

A MultiViews search is enabled by the MultiViews Options. If the server receives a request for /some/dir/foo and /some/dir/foo does not exist, then the server reads the directory looking for all files named foo.*, and effectively fakes up a type map which names all those files, assigning them the same media types and content-encodings it would have if the client had asked for one of them by name. It then chooses the best match to the client's requirements, and returns that document.

The MultiViewsMatch directive configures whether Apache will consider files that do not have content negotiation meta-information assigned to them when choosing files.

Global Options:
 top home search open messages active posts  
 

Home / Forums Index / Code, Content, and Presentation / Apache Web Server
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Home ¦ Free Tools ¦ Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About ¦ Library ¦ Newsletter
WebmasterWorld is a Developer Shed Community owned by Jim Boykin.
© Webmaster World 1996-2014 all rights reserved