Thanks so much for your help. I've finally been able to get it going. In the end, apparently it was the debugging settings in config.php that were causing the problems (as you had also suggested to me).
I've now set them in the following manner:
ini_set ('display_errors', 'off');
ini_set ('log_errors', 'off');
ini_set ('display_startup_errors', 'off');
ini_set ('error_reporting', E_ERRORS);
and I no longer have problems logging in.