0

server { listen 80 default_server; listen [::]:80 default_server;

    root /var/www/html;
    index index.php  index.html index.htm;

    server_name _;

    location / {
            try_files $uri/ /index.html index.php;
    }

    location ~ \.php$ {
    include snippets/fastcgi-php.conf;
    fastcgi_pass unix:/run/php/php7.4-fpm.sock;

}

How to make a web server can read the sub folder (the sub folder name is pendaftaranpkl with index.php) I try to access it but its doesn't show anything.

  • 1
    [End user Question are not on Topic, als also Private-Equipment](https://serverfault.com/help/on-topic). if the Folder exists on /var/www/html/pendaftaranpkl it will be useable by url/pendaftaranpkl. By Default NGINX forbid directory listing. You can use `autoindex on;` to disable the default behavior. I flagged also your question for movement, due offtopic on serverfault. Please dont Crosspost your question on Superuser.com instead flag also it for movement. – djdomi Aug 29 '22 at 05:36

0 Answers0