Page 1 of 1

White Page just with 'Error'

Posted: Mon Apr 16, 2018 10:26 am
by LeonieC
Note: I'm very much an amateur.

I have developed a new website using the latest version of Joomla 3.X.
It is in a sub-directory under my own web site while being developed.

In my excitement to move it to the new host site and launch...I forgot to back it up. :(

I downloaded the Joomla files, and downloaded the database and migrated to the new hosting site, changed the paths' in the config.php etc. I've done this once before with success, but doesn't mean I didn't do something wrong.

when I loaded the site all I got was a white page with one word: Error.

I thought it was from the migration but I have since discovered the original development site has the same issue.
All the files seem to be in place, as is the database. The config file appears to be the same. But still a white page with one word: 'Error'.

I must have done something without realising it. Is this a database connection error? I just can't find what is wrong.

Very much appreciate your help, especially if you treat me like a kindergarten developer with minimal jargon understanding.

Leonie

Re: White Page just with 'Error'

Posted: Mon Apr 16, 2018 10:44 am
by AMurray
FPA Report please: viewtopic.php?f=714&t=793531

Also can you turn on error reporting to maximum (in configuration.php file and/or any local php.ini file - or even a setting through the hosting control panel might enable such error reporting).

(a) The configuration.php variable is the one $error_reporting = "X"; (change to "maximum").
(b)The php.ini file one is (b) "display_errors="OFF/ON" (change to "On").

The FPA report will tell us what your system has currently set in those files (which is why the report is a useful tool when posting technical questions like this)

Re: White Page just with 'Error'

Posted: Mon Apr 16, 2018 10:47 am
by AMurray
If you suspect it is the database credentials that are wrong, try changing the DB user (in cPanel for example) then update the detail in the configuration.php file with those same details.

Re: White Page just with 'Error'

Posted: Mon Apr 16, 2018 10:48 am
by AMurray
In moving your site, the one thing that would have made that easier, is using a backup made with Akeeba Backup, then you simply move the site to new domain, new hosting or server by restoring the archive file with Akeeba Kickstart. No manual effort or importing databases required - the Kickstart script does all the hard work

Re: White Page just with 'Error'

Posted: Mon Apr 16, 2018 11:12 am
by LeonieC
Thank you AMurray

I've never done this before. I created a new user in MySQL databases, and added them to the database for the web site.

I changed the database user and password in the config.php and this hasn't fixed the problem.

Re: White Page just with 'Error'

Posted: Mon Apr 16, 2018 11:27 am
by LeonieC
One thing to highlight here...for the moment, forget about the migrated site. I've somehow broken the original development site. The migrated site was simply replicating the error. The original development site is what I need to fix. After that I can have a go at migrating it.

I wasn't changing the config or database on the original development site... I thought all I did was download the site and database.

If we think outside the box, what else might cause the white page with 'error'?

Re: White Page just with 'Error'

Posted: Mon Apr 16, 2018 12:59 pm
by mbabker
That only happens in Joomla if the global error handler is given a non-error based object or there is a fatal error rendering the error page template. So, first you're getting an error page from something else, and second your error page (check your template for an error.php file) isn't rendering.

Enable debug mode (set debug to "1" in configuration.php) and set error reporting to maximum (set error_reporting to "maximum" or "32767" in configuration.php). Should give a little more info.

Re: White Page just with 'Error'

Posted: Mon Apr 16, 2018 8:06 pm
by LeonieC
Thank you mbabker
After those changes, here is the error message:

Error: Failed to start application: Could not connect to MySQL server.
Warning: session_write_close(): Failed to write session data (user). Please verify that the current setting of session.save_path is correct (/tmp) in /home/*user*/public_html/*user*/libraries/joomla/session/handler/native.php on line 194


More info:
1. The site has been developed under php7 with no issues. After reading some other support threads I tested the site under 5.7. This changed the error message to just : Error: Failed to start application: Could not connect to MySQL server

2. I've reset the database password and checked all details in the config.php match the correct database and password


Not sure if this gives any more useful info?

Re: White Page just with 'Error'

Posted: Mon Apr 16, 2018 9:30 pm
by mbabker
All requisite PHP extensions are installed and enabled?
Database user has ample permissions to establish the connection?
Nothing blocking the connection on the server?

Re: White Page just with 'Error'

Posted: Wed Apr 18, 2018 5:31 pm
by LeonieC
I've been working with my host and I think we may have an understanding of what has happened.

mbabker, read this scenario below and let me know if you think this is possible.


1. new joomla site created on User1 hosting Account on a hosting site. database name user1_jos1

2. above site is moved manually to User2 hosting Account, which happens to be on the same hosting site server. More work is done on the site here to develop it further. all this time the config.php file still has usesr1_jos1 as the database name, even though the file path has been changed.


Is it possible that the site on User2 is still accessing the user1_jos1 database from User1 hosting account? Remembering they are both with the same host and on the same server?


If so, then when I moved the site from User2 back to User1 and overwrote the user1_jos1 database on User1, then I quite literally destroyed the database and neither user site will work.

This is what we think may have happened, the host is going to see if they can restore the database file from a backup. Then, if we can get the site running I would only have lost a few days work.

Re: White Page just with 'Error'

Posted: Wed Apr 18, 2018 9:47 pm
by mbabker
Depends on the security mechanisms in place on the server. I don't know what your backend hosting platform is but I don't think cPanel and WHM allows this type of "cross account" authentication (user 2 wouldn't be able to access user 1's databases), that's not to say that other platforms don't allow that and it definitely isn't a default MySQL platform behavior.

Re: White Page just with 'Error'

Posted: Wed Apr 18, 2018 9:57 pm
by LeonieC
Ok, well thank you.
I guess we will find out today!

looks like I might have to rebuild the site. A pain but not too difficult. It's just a simple site and I still have all the design elements.

Is there any way I can extract page text?

Re: White Page just with 'Error'

Posted: Thu Apr 19, 2018 7:12 pm
by LeonieC
:) I have my site back!

We restored the database from the hosting backup and everything is working.
So mbabker, the problem was exactly as I guessed - the site was accessing the database across the server.

A steep learning curve for me, but a valuable one. I made several mistakes that caused the problem, lost a lot of sleep but I have certainly gained some knowledge.

thank you for your help with this.
L

Re: White Page just with 'Error'

Posted: Sat Oct 27, 2018 3:01 pm
by uaintgotthisid
This was caused for me by the error.php as Michael Babker explained. I updated my template and that resolved the issue. I also disabled a plugin. Error reporting on maximum helped me identify that.

Re: White Page just with 'Error'

Posted: Sat Dec 22, 2018 7:27 pm
by boriskarloff
In my case, the database password was changed.
I just update the configuration.php with the new password and... it works!

Re: White Page just with 'Error'

Posted: Tue Dec 25, 2018 6:23 am
by leolam
mbabker wrote:
Wed Apr 18, 2018 9:47 pm
but I don't think cPanel and WHM allows this type of "cross account" authentication (user 2 wouldn't be able to access user 1's databases),
Michael, this is possible if both users have been added to the same database in cPanel

Leo 8)

Re: White Page just with 'Error'

Posted: Tue Jun 11, 2019 7:43 am
by kregus
For me the problem was that my web server hard disk was full.