Only lists the Index page

[ad_1]

Hi, yes as you already found out this is caused because the webserver didn’t find a “DirectoryIndex” this means the index.php file wasn’t found. I can see you have the index.php file but it is called index.php_old, you need to remove the _old from the name.

Also the webserver is configured to display the files instead of executing the php code. This configuration should be changeable in the .htaccess file, you need to remove this line of code:

Options +Indexes

The .htaccess file should be located in the same folder as the WordPress installation, and it is a hidden file, so make sure to also display hidden files in order to find it. You can then just open the file in any text editor and remove this line of code.

Thread Starter
Alrich

(@alrichst)

Hi Benni,

Thank you very much for the speedy and kind assistance. I managed to get he website to display by removing the _old as you suggested. Thanks!

I managed to find the .htaccess file, but cannot see that line you are referring to.

php -- BEGIN cPanel-generated handler, do not edit

Set the “ea-php80” package as the default “PHP” programming language.

AddHandler application/x-httpd-ea-php80 .php .php8 .phtml

php -- END cPanel-generated handler, do not edit

BEGIN cPanel-generated php ini directives, do not edit

Manual editing of this file may result in unexpected behavior.

To make changes to this file, use the cPanel MultiPHP INI Editor (Home >> Software >> MultiPHP INI Editor)

For more information, read our documentation )

php_flag display_errors Off php_value max_execution_time 330 php_value max_input_time 360 php_value max_input_vars 1000 php_value memory_limit 328M php_value post_max_size 328M php_value session.gc_maxlifetime 1440 php_value session.save_path "/var/cpanel/php/sessions/ea-php80" php_value upload_max_filesize 128M php_flag zlib.output_compression Off
php_flag display_errors Off php_value max_execution_time 330 php_value max_input_time 360 php_value max_input_vars 1000 php_value memory_limit 328M php_value post_max_size 328M php_value session.gc_maxlifetime 1440 php_value session.save_path "/var/cpanel/php/sessions/ea-php80" php_value upload_max_filesize 128M php_flag zlib.output_compression Off END cPanel-generated php ini directives, do not edit BEGIN WordPress The directives (lines) between "BEGIN WordPress" and "END WordPress" are dynamically generated, and should only be modified via WordPress filters. Any changes to the directives between these markers will be overwritten. END WordPress
  • This reply was modified 28 minutes ago by Alrich.

Hi, seems like it only displayed the contents of the directory because it didn’t find the index.php, in this case you don’t have to do anything with the .htaccess file.

I’m glad I could help you out with your issue 🙂

Thread Starter
Alrich

(@alrichst)

I really do appreciate your kind assistance. Thank you very much Benni!

 

This site will teach you how to build a WordPress website for beginners. We will cover everything from installing WordPress to adding pages, posts, and images to your site. You will learn how to customize your site with themes and plugins, as well as how to market your site online.

Buy WordPress Transfer