01-23-2010
That's odd.
I created a .htaccess file with rubbish, and got an internal server error.
Then I chmod'd the file to 400 and got forbidden, then deleted it and still got forbidden.
After restarting the webserver, it works OK again.
What does the error_log say?
Last edited by Scott; 01-23-2010 at 03:20 PM..
10 More Discussions You Might Find Interesting
1. UNIX for Advanced & Expert Users
I have installed Apache lots of times before. I have recently installed apache on FreeBSD. And it gives me all the time 403 Frobidden - you don't have permittion to access / directory. I have checked permitions. I've got -rwxrwxr-x for for all Apache DocumentRoot. I've checked Files directive in... (6 Replies)
Discussion started by: solvman
6 Replies
2. Linux
When i go to my browser and type both localhost or the ip, i get Forbidden, you do not have permission to access / on this machine
Whys that ? (1 Reply)
Discussion started by: perleo
1 Replies
3. Shell Programming and Scripting
Hi ,
I am using shell script to connect to a https site and download all the files in a directory.
eg:
wget --no-check-certificate -r -np --user=<username> --password=<passwd> -O temp.txt https:<website>/<dirname>
Error :
HTTP request sent, awaiting response... 403 Forbidden
07:40:20... (0 Replies)
Discussion started by: mohanpadamata
0 Replies
4. UNIX for Dummies Questions & Answers
Hello all, i'm stumped.... I need to list all directories with all there info and exclude the files, then vice versa. I am not sure if I need to string several ls commands together or how to even do that. I believe I need to do some variation of ls -l but need to figure out how to take out the... (5 Replies)
Discussion started by: citizencro
5 Replies
5. UNIX for Dummies Questions & Answers
Hi!
I am trying to find all text files in my home directory that contain the string "C-d" so I tyied this :
cd ~
find . -type f -exec grep -l "C-d" {} +
but it took very long so I tryed this :
ls -aR | xargs file |grep text
but it didn't descend in the directories and it said :... (3 Replies)
Discussion started by: kelamahim
3 Replies
6. UNIX for Dummies Questions & Answers
I have a file with about 29,000 website names. I would like to find a script that would test if each website name is current/active or not. If not it should check if the page is: Forbidden, 404 Error... (1 Reply)
Discussion started by: dcovnton
1 Replies
7. Web Development
I have been troubleshooting a couple of problems all day that have to do with this all day. I do not know if you need to know the code I used in php but if you do I will post it.
I hope that you can see the .pngs.
Thanks ahead of time.
Using phpMyAdmin and creating files.... somehow... (2 Replies)
Discussion started by: iHaveAQuestion
2 Replies
8. Shell Programming and Scripting
Hi Friends,
I did an extensive search over the internet and tried all possible solutions that were recommended, but couldn't figure this out.
Please see this link
http://www.dli.gov.in/data6/upload/0159/808/PTIFF/00000007.tif
It works.
But, when I try the following command
wget -r... (7 Replies)
Discussion started by: jacobs.smith
7 Replies
9. Red Hat
Good evening, i've got a problem. I fail to enter "Manager App" in Apache Tomcat/9.0.0.M9 on server, it says "403 Access Denied». for example, server address is 192.168.1.4, when I type 'localhost ' in the browser and press "Manager App", then everything is ok. but if I enter 192.168.1.4 and press... (0 Replies)
Discussion started by: v.k.l.chr.by
0 Replies
10. UNIX for Advanced & Expert Users
tcsh: have the following in .cshrc (or .tcshrc)
set prompt=": "
zsh: have the following in .zshrc
PS1="%# "
bash: have the following in .bashrc
PS1='\$ 'Lacking direct support this is a good approximation. (0 Replies)
Discussion started by: MadeInGermany
0 Replies
LEARN ABOUT DEBIAN
plack::middleware::static
Plack::Middleware::Static(3pm) User Contributed Perl Documentation Plack::Middleware::Static(3pm)
NAME
Plack::Middleware::Static - serve static files with Plack
SYNOPSIS
use Plack::Builder;
builder {
enable "Plack::Middleware::Static",
path => qr{^/(images|js|css)/}, root => './htdocs/';
$app;
};
DESCRIPTION
Enable this middleware to allow your Plack-based application to serve static files.
If the given request matches with the pattern defined in "path", this middleware will try to locate the file in "root". If the file exists
it will be served but otherwise 404 response will be returned. See "pass_through" option below to change this behavior.
If the requested document is not within the "root" (i.e. directory traversal) or the file is there but not readable, a 403 Forbidden
response will be returned.
The content type returned will be determined from the file extension based on Plack::MIME.
CONFIGURATIONS
path, root
enable "Plack::Middleware::Static",
path => qr{^/static/}, root => 'htdocs/';
"path" specifies the URL pattern (regular expression) or a callback to match with requests to serve static files for. "root" specifies
the root directory to serve those static files from. The default value of "root" is the current directory.
This examples configuration serves "/static/foo.jpg" from "htdocs/static/foo.jpg". Note that the matched "/static/" portion is still
appears in the local mapped path. If you don't like it, use a callback instead to munge $_:
enable "Plack::Middleware::Static",
path => sub { s!^/static/!! }, root => 'static-files/';
This configuration would serve "/static/foo.png" from "static-files/foo.png" (not "static-files/static/foo.png"). The callback
specified in "path" option matches against $_ and then updates the value since it does s///, and returns the number of matches, so it
will pass through when "/static/" doesn't match.
If you want to map multiple static directories from different root, simply add "this", middleware multiple times with different
configuration options.
pass_through
By turning on this option, this middleware will pass the request back to the application for further processing, if the incoming
request path matches with the "path" but the requested file is not found on the file system.
AUTHOR
Tokuhiro Matsuno, Tatsuhiko Miyagawa
SEE ALSO
Plack::Middleware Plack::Builder
perl v5.14.2 2011-06-22 Plack::Middleware::Static(3pm)