Table of contents:
There are lots of things that can go wrong when you are installing or updating Joomla 3.x. This tutorial will teach you how to deal with most of those issues and fix everything that is broken. So, if you are experiencing problems when updating or installing Joomla, start channeling your inner Fix-It Felix and follow this guide as close as possible.
Never-ending database installation
There are at least two mentions of the fact that you SHOULD have disabled Magic Quotes in your PHP installation in our Joomla installing guides. These mean features are breaking errors display first and main installation second and that’s why it won’t end. Thankfully, there’s a simple solution that is located at the next issue.
I get Magic Quotes error!
Sometimes your Joomla installation is actually able to survive and signal you about the reason why it cannot be completed. If it happened, you have to disable Magic Quotes in your PHP installation and that’s how you can do it:
First way of disabling Magic Quotes is changing values in php.ini. Find the file on your website and add following strings to it:
magic_quotes_gpc = Off magic_quotes_runtime = Off magic_quotes_sybase = Off extension=pdo.so extension=pdo_mysql.so
If your hosting provider doesn’t like the fact that you are changing php.ini – ask its support team to turn Magic Quotes off manually.
Second way of disabling Magic Quotes is by addressing php.ini throughout .htacess. Just add there following lines:
php_flag magic_quotes_gpc Off php_value magic_quotes_gpc Off
Now you have to revisit your Joomla installation screen and actually complete it. If your provider does not like the fact that you changed .htacess – ask them to do it. Also create a support ticket to your hoster if you are continuing to experience problems.
If you are wondering what in the world Magic Quotes are, there’s an answer: Magic Quotes are a process that automatically releases incoming data to the PHP script. This feature has been REMOVED in PHP 5.4.
This is not actually an issue, but it pisses a lot of people off anyway. So, if you don’t want Joomla to tell you when something went wrong by writing it on top of every page – you will like this solution to your problem.
Method 1. Global Configuration
The simplest solution ever – go to your Global Configuration menu and disable the parameter called Display Errors.
Method 2. Modifying php.ini
If previous solution did not work, open your php.ini file (you may find it with search in your website root directory or by going for XAMPP manual) and locate following string:
display_errors = On or display_errors = 1
Change this value to:
display_errors = Off or display_errors = 0
You are done. Just make sure to reboot your Apache installation when you are changing php.ini.
Method 3. Changing .htaccess
If the first method did not work and you can not find your php.ini (or do not have access to it), you may try modifying it throughout .htaccess with is located in your website’s root folder. Add this to the file:
php_flag display_errors off
If it did not work, change “off” to “0”.
If neither of these methods worked, you should write a support ticket to your internet provider.
Disabling the Safe Mode
Safe Mode is a php feature that allows system to be more stable and defend against incoming issues. Unfortunately, it is incompatible with Joomla, but fortunately there is a quite simple solution to this problem – editing your php.ini. Add this string to the file:
safe_mode = Off or safe_mode = 0
If you are unable to access your php.ini, there’s still a way for you to do it. Just add this line to .htaccess:
php_admin_flag safe_mode Off or php_admin_value safe_mode 0
Some Apache commands allow you to change this line from the Apache as well.
The command and feature were completely removed from PHP 5.4
Handling the Strict Standards Error
This is a very uncommon problem when it comes to commercial servers, but it may appear when you are installing Joomla on your own computer as a local host. This looks like an entire screen of warnings that begin with or feature this:
Strict Standards: Accessing static property JCache::$_handler as nonstatic
Remember – these are warnings, not critical errors, so instead of fixing them, you can merely change the rules of their appearing. To do this, open your php.ini and set following parameters like this:
error_reporting = E_ALL & ~E_NOTICE & ~E_DEPRECATED display errors = Off
Now restart Apache for changes to take effect. If you don’t know how to do this, access your server tutorial or support team.
Defining your output buffering mode
This is not a problem or a warning – it is just a recommendation. But if you noticed that your website is running slow, you may try to improve it by setting Output Buffer on (or setting it off if you are experiencing any troubles). Output buffering is a mechanism for controlling how much output data (excluding headers and cookies) PHP should keep internally before pushing that data to the client.
To enable or disable this mechanism, you will have to edit the following line in php.ini. It has three possible value types:
output_buffering = On output_buffering = Off output_buffering = 4096
While there may be some other value than 4096, it is suggested to you to leave it like this – this is the most stable value when buffer is still being used. Turning it to On will make buffer size unlimited which will make it уму faster, but may decrease stability. Turning it Off will decrease speed, but it is the most stable value at all.
Also, you can try accessing php.ini throughout .htaccess by adding to it this line:
php_value output_buffering X
Where X is the value you need.
Change register_globals from On to Off
There’s a possible security hole in a classic PHP installation and, even though it is quite minor, you’d better try to turn it off. It’s called register_globals and to change its mode, you will have to access php.ini. Find the following string:
register_globals = On
And modify it to look like this:
register_globals = Off
You may also access it throughout .htaccess by adding the following line to the file:
php_flag register_globals Off
Seeing 500 Internal Server Error
There may be an error you will see on your front-page (or, instead your front-page) that will look like “Error 500: Internal Server Error”). There may be quite a lot of reasons for it to appear, but what is the most important – you, usually, have nothing to do with them. The error means that server is misconfigured and cannot send the data your browser asked for. Also, your server may be under DDOS attack or heavy number of visitors – if this is the reason (you can ask your hoster about that) – you may want to buy faster and more protected server.
This is a list of possible reasons of 500 Internal Server Error:
- Misconfigured web server file or folder read and write permissions - check your php.ini and .htaccess files.
- Corrupted file(s).
- Script issues
Blank screen after upgrading to Joomla 3.2
Joomla 3.2 brought a lot of changes, but what is the most important for you – new requirements for servers and extensions. It means, that if your website or your server is incompatible with Joomla 3.2, but you still upgraded it – you are in for a lot of trouble. Blank screen means that your system tries to tell you something through display_errors mechanism, but fails. But there is a solution to the problem:
Joomla will tell you to turn on display_errors, and while it is needed too, it is not the complete solution. Find a file called configuration.php in root folder of your website and open it. Now you need this string:
public $error_reporting = ‘default’
But default is not enough. Change the value of the string to “maximum” so it will look like this:
public $error_reporting = ‘maximum’
Now refresh your website page and see the real problem you need solution for!
Increasing PHP upload limit
There are times when your system can not finish the installation for what looks like broken installation package, but on your PC you can unpack it without any trouble. It means that your server is misconfigured or very weak. If it is the former, there is a solution. There are four strings that defy the limits of uploading files on server in php.ini file. They are:
If you are experiencing any problems with uploading files, you will need to change them throughout .htaccess or directly (sometimes your hosting provider does not allow .htaccess overrides). To do this the first way, open .htaccess and add following strings:
php_value post_max_size 8M php_value upload_max_filesize 8M php_value max_execution_time 60 php_value memory_limit 128M
These values are Joomla recommended settings. You may want to change them, but then you are on your own for any trouble that comes in.
If you do not have access to .htaccess, you may do it another way – by changing the lines in php.ini directly. Make them accept these values:
Make them accept these values:
post_max_size = 8M upload_max_filesize = 8M memory_limit = 128M max_execution_time = 60
This should fix inability of your server to unpack or upload Joomla. If the error continues – check FTP permissions of \tmp\ directory – it should have at least 755.
Where is the php.ini file?
There is quite a lot of locations for your php.ini to be in. It depends on your server, server version and you hosting provider’s settings. Here is a list of the most common locations of php.ini:
- cPanel: On cPanel Shared Servers php.ini is located in Joomla root file directory. cPanel may have a special wizard for you in the Software services section.
- Parallels Plesk Panel: /etc/php.ini
- XAMPP: C:\xampp\php\php.ini
- Ubuntu: /etc/php5/apache2
- GoDaddy servers: You need to create your own and place it in the Joomla root directory
If you are running PHP5 instead of PHP4, your php.ini file will be called php5.ini
Failed to connect to your MySQL database server
If you are getting this error, it means that your Joomla installation script is unable to connect to MySQL database. Check once more if the username, password, hostname and database name are valid.