phpMyAdmin config.header.inc.php broken

1

I have installed phpMyAdmin 4.0.10 on an Ubuntu 14.04.3 LTS Server machine. Everything works fine, but I want to add a banner to the top of the web pages with a legal notice.

I should be able to achieve this by adding some code to the file /etc/phpmyadmin/config.header.inc.php, but if I add any kind of not ccommented out text to the file, phpMyAdmin doesn't load. Instead, an empty page is displayed.

Note that this happens regardless of what I write to the file: HTML code, PHP, Scripts, plain text, etc. Can you help me? Thanks.

user2747949

Posted 2016-01-02T17:27:56.520

Reputation: 55

Check your web server log and check what's the problem. – nKn – 2016-01-02T17:33:47.427

@nKn I found two types of error in the logs: [:error] [pid 22598] [client XXXXX] PHP Parse error: syntax error, unexpected end of file in /etc/phpmyadmin/config.header.inc.php on line 9 and [:error] [pid 25511] [client XXXXX] PHP Parse error: syntax error, unexpected '<' in /etc/phpmyadmin/config.header.inc.php on line 9. However there is no syntax error. – user2747949 – 2016-01-02T17:58:46.653

Well, that's why the page appears blank. You must follow the PHP format, not plain text, not HTML, just PHP with its syntax. – nKn – 2016-01-02T18:01:04.237

@nKn I see, I solved the problem now. Thank you for clarifying. If you write your comment as an answer I can flag my question as solved. – user2747949 – 2016-01-02T19:55:20.003

Answers

0

When you get a blank page it very probably mean that you have a syntax error in one of your files.

The config.header.inc.php file must have PHP format. No plain text, HTML or any other. Once you edit it, you can check the PHP syntax with this command:

php -l config.header.inc.php

nKn

Posted 2016-01-02T17:27:56.520

Reputation: 4 960