My website won’t load and my browser reports errors

My website won’t load and my browser reports errors

How solutionate errors in the website, php

During the development of your website, or during operation, your website may not work from any browser. In order to prevent this error, we recommend following these steps to verify what the problem is.

 

Why my website won´t load?

1: Check the message on the screen as well as your internet connection:

The first indicator of the error of your website is the message you receive in the browser. Verify that other websites work to rule out that your Internet connection is the problem.

The list of errors is infinite, therefore it is advisable to search Google for the exact error message. We added some example errors in Chrome

– HE’S DEAD JIM

Indicates that your computer does not have enough memory to load the page. Close other applications to create memory and reload the website.

– NET_ERROR(INTERNET_DISCONNECTED, -106)

The internet connection does not work. Restart your router and try other websites.

– NET_ERROR(NAME_RESOLUTION_FAILED, -137)

There are problems in domain DNS resolution. To correct this problem, check the next step.

– NET_ERROR(PROXY_CERTIFICATE_INVALID, -136)

Your internet connection is made through the proxy. Certificates or proxy permissions may be invalid. Check your network administrator.

– NET_ERROR(SSL_CLIENT_AUTH_PRIVATE_KEY_ACCESS_DENIED, -134) / NET_ERROR(PROXY_CERTIFICATE_INVALID, -136)

The SSL certificate of the website you are visiting has expired or is invalid. Sometimes this error occurs when your computer has misconfigured the time and date.

– The connection is not private /NET::ERR_CERT_COMMON_NAME_INVALID

The domain you are visiting requires access via HTTPS but does not have an SSL certificate installed. This usually happens when accessing webmail or when you have an application installed on your website that forces the browser to use SSL without having it installed.If it is your own website that is affected, this does not pose a security threat. To continue you can click Advanced and proceed. Antivirus can also generate this error.

If you want to buy an SSL certificate, you can visit https://www.clickpanda.com/ssl/

 

If you do not receive any of the error messages mentioned or the page is blank, proceed to the next step…

 

2: Check the DNS configuration of your domain.

First, check which records are currently resolving in the global DNS servers. To do so, visit www.digwebinterface.com and do a search with the affected domain.

If you see that it does not resolve any records, you should check your Nameservers.

If you purchased a hosting plan with ClickPanda, you should check that the NAMESERVER records point to the ones you received in your plan’s welcome email. For more information, you can visit our support article on How to change my Nameservers?

If you don’t have a Hosting plan with ClickPanda, you can use our DNS service, and you must create an A-type record pointing to the IP address of your server,

For more information on how to use our DNS service and modify the type A record, visit our article How can I change my domain’s DNS records? Remember that you must only have one type A record in the main domain. Having more than one can cause problems on your website. Furthermore, you should have a CNAME type record at the same time as a type A record.

 

3: Check the index file of your hosting plan:

For your website to be shown on the Internet, you must have an index file in the root folder of your hosting plan.  This file must have some valid extension for the Internet depending on how the website was developed (example: index.html, index.php, index.htm, index.aspmx etc).

For the main domain, the folder root is called public_html. The additional domains, you define the folder root while simultaneously adding the additional domain. For more information, you can visit these support article:   How to add additional domains in Cpanel?

4: Check the Apache error log:

When the files have incorrect permissions or when a dependency is needed, it is possible to find the error inside the Cpanel error log. To see it, you must follow the steps of this support article log of errors in Cpanel.

Once you have identified the error, you can correct it in the specific file. For example, if the error indicates something such as “Permission denied”, you should check that the mentioned file has 755 permissions. If you want to find out which one you can change follow the instructions in our support article on How to manage files in Cpanel?

5: Check the error file

If you did not find the problem in the Apache error log, it is possible that it is a problem related to code syntax or MySQL connections. For this, you should look for a file called error_log in the folder associated with the website you are visiting. For example, the error log of your main domain should be in the folder public_html.

In case you don’t find this file, this indicates that there are no MySQL errors or that your website is not delivering an error output. If that is the case you should continue to the next step.

6: Enable PHP errors or the debug mode of your CMS

If your website is developed in PHP, you can add the following line of code at the beginning of the file to show the syntax or function errors in the browser. Add the following code just after “<?php”:

ini_set(‘display_errors’,1);
ini_set(‘display_startup_errors’,1);

error_reporting(E_ALL);

If you use a CMS to develop your website (Example: WordPress, Joomla, Prestashop etc) you can enable the debug mode. Here are some examples:

Enable debug/debug mode in WordPress:

WP_DEBUG is a PHP constant (a permanent global variable) that, when set to true, activates the debug mode in WordPress. Its default value is false and recommended using the following file to set its value: wp-config.php (located at the root of the site) in one of the following ways:

define(‘WP_DEBUG’, true);

define(‘WP_DEBUG’, false);

It is not advisable to use WP_DEBUG. Like the other debugging tools permanently on production websites (websites accessible to the public) all of these errors, grave or not, would be displayed on the screen to all users of the site. This is not desirable. The purpose of these tools is to debug code in test environments before opening the site to the public. To enable debug mode, the value of the WP_DEBUG variable must be true Enable debug/debug mode in Joomla

From the Joomla admin panel, go to Global Settings, and select “YES” in the System Debugging option.

 

Errors in the system
Debug of errors in the system

7: Check the bug log in the Browser developer tools:

If you don’t have any errors, and you still can’t see your website or it doesn’t load completely, you can check the bug log in your browser’s developer tools.

For example, in Google Chrome, press the F12 key while your page loads and in the “Console” or “Console” section you can see errors related to file uploads or errors in javascript. Here is an example of the administration console:

 

Common errors in websites
Log of errors in Google Chrome

 

You can leave us your opinion in the comments box, we like to know what you think about these topics and about us.

Visit www.clickpanda.com to get more information about us.

Leave a Reply

Your email address will not be published. Required fields are marked *