Hello. I have successfully activated InfinityFree’s free hosting and activated Let’s Encrypt certificates. The site I’m moving is built with WordPress, so I’ve followed all the steps correctly. I downloaded the files and the database correctly. I created a new database and assigned the correct credentials. Everything is fine, but so far the page keeps throwing me an HTTP ERROR 500. I have no idea where the error is, but I don’t know if the directory is correct. My domain is ahmp.org.pe, and I understand that I have to place all the files in the htdocs folder. Some tutorials tell me they should be in the public_html folder, but I can’t find one, and it doesn’t seem like the correct path.
Hello. Now I can visualize the error and it shows me the following:
Warning : require_once(/home/vol8_8/infinityfree.com/if0_39160854/ahmp.org.pe/htdocs/wp-settings.php): Failed to open stream: No such file or directory in /home/vol8_8/infinityfree.com/if0_39160854/ahmp.org.pe/htdocs/wp-config.php on line 96
Fatal error : Uncaught Error: Failed opening required ‘/home/vol8_8/infinityfree.com/if0_39160854/ahmp.org.pe/htdocs/wp-settings.php’ (include_path=‘.:/usr/share/pear/’) in /home/vol8_8/infinityfree.com/if0_39160854/ahmp.org.pe/htdocs/wp-config.php:96 Stack trace: #0 /home/vol8_8/infinityfree.com/if0_39160854/ahmp.org.pe/htdocs/wp-load.php(50): require_once() #1 /home/vol8_8/infinityfree.com/if0_39160854/ahmp.org.pe/htdocs/wp-blog-header.php(13): require_once(‘/home/vol8_8/in…’) #2 /home/vol8_8/infinityfree.com/if0_39160854/ahmp.org.pe/htdocs/index.php(17): require(‘/home/vol8_8/in…’) #3 {main} thrown in /home/vol8_8/infinityfree.com/if0_39160854/ahmp.org.pe/htdocs/wp-config.php on line 96
Apparently you didn’t
because some files are missing.
You’ll want to fix the WordPress installation.
Hi. So you’re seeing two errors? I’m worried about the first one because I’m sure I uploaded the database correctly, but just to be sure, I’ll delete it and upload it again.
- These two errors comes from the same place.
- It’s a WordPress file being missing, not the database.
I understand your point, but in the tutorial you provided, by replacing all the files with the native WordPress file, wouldn’t that mean I’m back to a blank page? Because all the files that contain my old website would be replaced with a blank one. Also, the error I posted points to a problem that exists in only one file. Wouldn’t it be better to fix that line?
I just followed the guide in the link you provided (to rule out errors) and now I get the following error:
Warning : mysqli_real_connect(): (HY000/2002): No such file or directory in /home/vol8_8/infinityfree.com/if0_39160854/ahmp.org.pe/htdocs/wp-includes/class-wpdb.php on line 1988
No such file or directory
This means you’re using localhost
as the database hostname. The correct value should look like sql***.infinityfree.com
, where ***
are numbers. You can find the database hostname to use in the client area and control panel.
Thanks for the reply. I didn’t understand which line or file I should change in that case. I know what credentials I should enter, but I don’t know where to do them. The line mentioned in the error message is line 1988, where you can read:
mysqli_real_connect( $this->dbh, $host, $this->dbuser, $this->dbpassword, null, $port, $socket, $client_flags );
Then you are looking at the totally wrong file.
You should be looking for wp-config.php
, where it contains the actual values provided to that line.
No, because the majority of your website is not in the WordPress files themselves, it’s in the database.
And for the rest of your website, which are mostly images, plugins, themes, etc, won’t be replaces, because a stock WordPress installation doesn’t have those. So there’s nothing to be replaced with.
From your message, I understand that the lines to be changed are those in the wp-config.php file. However, I’ve double-checked that the database credentials are correct. Is there another file with that name in another location?
Please read again
We didn’t ask you to check the credentials.
You should be looking at the line that have DB_HOST
in it. Not the lines you’ve shared.
Thank you for your reply. I’m confused right now. Could you tell me which file I should change? I understand more or less, but so far I can’t see where to make the changes since I don’t see any path.
Hello. I understand. Since I’m using a translator, the highlighted words in your message are disappearing. I’ve already changed the ‘localhost’ to the correct name. However, the problem now is the one I mentioned before. The link forced me to reinstall WordPress, and my website looks empty. You can check it at the link: ahmp.org.pe
Hello. Even though I use a different template, I’m seeing that posts, menus, and other content aren’t appearing.
Most likely you did not
The theme you’re using doesn’t appear to support the latest PHP versions well. You can probably remove the deprecation warnings for now by disabling WP_DEBUG mode. But you might run into more issues later with future PHP or WordPress upgrades unless the theme is updated. If the current theme is no longer being updated, please consider switching to something that is still being maintained.
In general, avoid modifying WordPress core files. Anything that you’ll normally needs to change can be changed in the wp-config.php file.
If WordPress cannot find the database you configured initially, it will show the installation wizard. Do not go through the installation wizard unless you want a new website. If you already have a database with content which you want to use, you should go back and check your settings.
The good news is that your website data is probably not gone, and can be recovered simply by using the right settings.
To help you effectively, can you please provide the following:
- The database settings in the wp-config.php file (everything from DB_NAME until DB_COLLATE). You should hide the password, but leave everything else visible.
- Also please show the
$table_prefix
setting in wp-config.php. - A screenshot of the list of tables in phpMyAdmin of your database. Please share the entire page. I will need to see the database name, table list, and the number of rows in the table.
Let me tell you a few important points. I have three backups of the website (which was working correctly just two weeks ago). The first backup is the one I made myself, the second backup is packaged with the “All-in-One WP Migration and Backup” plugin (which can also be unzipped and uploaded via FTP), and the third backup is one I just requested from the hosting company where the website was located. Regarding the latter, I should explain that it weighs more than 2 GB since it contains all the files, including the CPanel and everything else we don’t need now. Well, I’ve re-uploaded my website to Infinityfree, but this time using the backup provided by my previous host, and the result is practically the same: the page appears with a generic template without any content (although this time it no longer throws the template error like the previous time), and when I go to ahmp.org.pe/wp-admin, the WordPress console appears without the themes I used, nor the pages or sections. I understand that my files are there, but for some reason they’re not showing up. Based on the database, it’s no more than 10 MB, and I find it odd that this is the reason the page isn’t loading with all its content. Please, I need all your help, as I’m worried I won’t be able to recover the page.