Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7969959
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 4, 20262026-06-04T07:19:17+00:00 2026-06-04T07:19:17+00:00

Once I’ve seen this before when I type a URL http://test.com/test/ , instead of

  • 0

Once I’ve seen this before when I type a URL http://test.com/test/, instead of give me a html page, it gives me a ‘file browser’ like interface to browse all the files in the given location.

I think it maybe a nginx module that could be enable in the location context.

The nginx.conf file:

worker_processes  1;
events {
    worker_connections  1024;
}
http {
    include       mime.types;
    default_type  application/octet-stream;
    sendfile        on;
    keepalive_timeout  65;
    server {
        listen       80;
        server_name  122.97.248.252;
                location /test {
                        root /home/yozloy/html/;
                        autoindex on;
                }
        error_page   500 502 503 504  /50x.html;
        location = /50x.html {
            root   html;
        }
    }
}

update the error.log

2012/05/19 20:48:33 [error] 20357#0: *72 open() “/home/yozloy/html/test” failed (2: No such file or directory), client: 125.43.236.33, server: 122.97.248.252, request: “GET /test HTTP/1.1”, host: “unicom2.markson.hk

I must misunderstand the location /test mean, I thought it meant when I type http://example.com/test, then it would access the root dictionary which is /home/yozloy/html/

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-04T07:19:18+00:00Added an answer on June 4, 2026 at 7:19 am

    You should try ngx_http_autoindex_module.

    Set autoindex option to on. It is off by default.

    Your example configuration should be ok

    location /{ 
       root /home/yozloy/html/; 
       index index.html; 
       autoindex on;
    }
    

    Without autoindex option you should be getting Error 403 for requests that end with / on directories that do not have an index.html file. With this option you should be getting a simple listing:

    <html>
    <head><title>Index of /</title></head>
    <body bgcolor="white">
    <h1>Index of /test/</h1><hr><pre><a href="../">../</a>
    <a href="test.txt">test.txt</a>                 19-May-2012 10:43            0
    </pre><hr></body>
    </html>
    

    Edit: Updated the listing to delete any references to test

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Once before, I was certain that you couldn't do this, but the other day
Once again, things work normally EXCEPT in IE6. Please look at http://bronautomotive.com/ to see
Once and for all I want to clearify this somewhat subjective and argumentative area
Once all three loads are complete... $(#sidebar a).live(click, function(e){ $(this).addClass(selected loading); $(#conceptual).load(conceptualUrl, null, function(){
Once, I used this query to select the number of items in order to
Once I have retrived an HTML string with the $.ajax function I put it
Once I do $(#obj).load(url) is there a way to get the loaded url from
Once you place [RequireHttps] on an action and user switches from HTTP to HTTPS,
Once in a while when I do git pull I start getting this error:
Once the user clicks an anchor tag I need to open a page in

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.