Question

index.php blank page NGINX

Posted December 29, 2021 161 views
NginxCentOS 8

index.php blank page NGINX please tell me step by step how to solve it

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

×
Submit an Answer
1 answer

Hello, @Thinklatest

Have you checked our tutorials on How To Install Linux, Nginx, MySQL, PHP (LEMP) stack On CentOS server? Please find the links to the articles bellow

https://www.digitalocean.com/community/tutorials/how-to-install-linux-nginx-mysql-php-lemp-stack-on-centos-7

https://www.digitalocean.com/community/tutorials/how-to-install-linux-nginx-mysql-php-lemp-stack-on-centos-8

If you haven’t checked those tutorials then make sure to check them out because they cover the whole process pretty well.

If you’ve already completed the tutorial on your CentOS droplet then check if the Nginx and the PHP-FPM services are running and double-check the virtual host of your domain name (or the main block if you try to access the index.php page using the droplet IP address).

Hope that this helps!
Regards,
Alex

by Mitchell Anicas
by Erika Heidi
In this guide, we'll get a LEMP stack installed on an CentOS 7 server. A LEMP software stack is a group of open source software that is typically installed together to enable a server to host dynamic websites and web apps. This term is actually an acronym which represents the Linux operating system, with the ENginx web server (which replaces the Apache component of a LAMP stack). The site data is stored in a MySQL database (using MariaDB), and dynamic content is processed by PHP.
  • i am using ubuntu 18
    installing Yiimp
    this is my config

    Source Generated by nginxconfig.io

    Updated by cryptopool.builders for crypto use…

    NGINX Simple DDoS Defense

    limitconnzone $binaryremoteaddr zone=connlimitperip:10m;
    limit
    conn connlimitperip 80;
    limit
    req zone=reqlimitperip burst=80 nodelay;
    limit
    reqzone $binaryremoteaddr zone=reqlimitperip:40m rate=5r/s;

    server {
    listen 443 ssl http2;
    listen [::]:443 ssl http2;

    server_name allphoto.in;
    set $base "/var/www/allphoto.in/html";
    root $base/web;
    
    # SSL
    ssl_certificate /etc/letsencrypt/live/allphoto.in/fullchain.pem;
    ssl_certificate_key /etc/letsencrypt/live/allphoto.in/privkey.pem;
    ssl_trusted_certificate /etc/letsencrypt/live/allphoto.in/chain.pem;
    
    # security
    include cryptopool.builders/security.conf;
    
    # logging
    access_log /home/crypto-data/yiimp/site/log/allphoto.in.app.access.log;
    error_log /home/crypto-data/yiimp/site/log/allphoto.in.app.error.log warn;
    
    # index.php
    index index.php;
    
    # index.php fallback
    location / {
        try_files $uri $uri/ /index.php?$args;
    }
    location @rewrite {
        rewrite ^/(.*)$ /index.php?r=$1;
    }
    
    # handle .php
    location ~ \.php$ {
        include cryptopool.builders/php_fastcgi.conf;
    }
    
    # additional config
    include cryptopool.builders/general.conf;
    

    }

    HTTP redirect

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

    server_name .allphoto.in;
    
    include cryptopool.builders/letsencrypt.conf;
    
    location / {
        return 301 https://allphoto.in$request_uri;
    }
    

    }

  • After installation its showing Blank pages only