Forum Moderators: coopster
The trouble is, I set that variable to 'http://localhost/phpMyAdmin/';
If anyone has any ideas on what I have done wrong I would be most appreciative.
Cheers
Does that mean the $cfgPmaAbsoluteUri varibale is incorrect or that there is another problem meaning phpMyAdmin isnt reading it properly? Because, it is set, it might be wrong but it is definitely set!!
$cfgPmaAbsoluteUri string
Sets here the complete url (with full path) to your phpMyAdmin
version. E.g.
[your_web.net...]
Well I reckon I have done that exactly and its just not happening for me. Perhaps I'll just have to go back to square one. Hope not though!
Cheers
Just checked my installation and what you tried all looks good. Try putting this after the point where you set the var:
print("<h1>cfgPmaAbsoluteUri: $cfgPmaAbsoluteUri</h1>");
exit;
if you see the var then at least you'll know that the config is being included, and if your var is being set.
otherwise, you may revert back a few versions of php to something less bleeding edge - i'm not sure phpMyAdmin offically supports 4.2 yet?
good luck.
error_reporting = E_ALL
More good luck ;)
$cfgPmaAbsoluteUri = 'http://localhost/phpMyAdmin';
print("<h1>cfgPmaAbsoluteUri: $cfgPmaAbsoluteUri</h1>");
exit;
But the error is exactly the same:
The $cfgPmaAbsoluteUri directive MUST be set in your configuration file!
I'll see if that error reporting level helps.
So if I cant even print out the variable using those 2 lines of code does that imply the actual index.php is failing to access the config file somehow?
Which appears to ne what generates the error. This seems to hard code this value to the variable - no if statement to test whether it has been supplied. I found this in:
C:\apache\htdocs\phpMyAdmin\lang\english.inc.php
Time to have a play with that and see what else we can break then!! If only I knew what I was doing here!!
-- start --
/**
* Your phpMyAdmin url
*
* Complete the variable below with the full url ie
* [your_web.net...]
*
* It must contain characters that are valid for a URL, and the path is
* case sensitive on some Web servers, for example Unix-based servers.
*/
$cfgPmaAbsoluteUri = 'http://intranet.localdomain/phpMyAdmin/';
/**
* Server(s) configuration
*/
-- end --
see libraries/common.lib.php arround line 384 for the code that prints your error.
more good luck ;)
****start****
/**
* Your phpMyAdmin url
*
* Complete the variable below with the full url ie
* [your_web.net...]
*
* It must contain characters that are valid for a URL, and the path is
* case sensitive on some Web servers, for example Unix-based servers.
*/
$cfgPmaAbsoluteUri = 'http://localhost/phpMyAdmin/';
/**
* Server(s) configuration
*/
$i = 0;
****end****
Am I right in thinking I give it the http path rather than c:\ path if I am running Apache?
All configurable data is placed in config.inc.php3.$cfg['PmaAbsoluteUri'] string
Sets here the complete url (with full path) to your phpMyAdmin version. E.g. [your_web.net...]
Don't forget the slash at the end of your url. The url must contain characters that are valid for a url, and on some servers, the path is case-sensitive.This setting can be dynamically completed. For example, you can try to use such a kind of code:
$cfg['PmaAbsoluteUri'] = (!empty($_SERVER['HTTPS']) ? 'https' : 'http') . '://'
. $_SERVER['HTTP_HOST']
. (!empty($_SERVER['SERVER_PORT']) ? ':' . $_SERVER['SERVER_PORT'] : '')
. substr($_SERVER['PHP_SELF'], 0, strrpos($['PHP_SELF'], '/')+1);or
$cfg['PmaAbsoluteUri'] = (!empty($_SERVER['HTTPS']) ? 'https' : 'http') . '://'
. $_SERVER['SERVER_NAME']
. (!empty($_SERVER['SERVER_PORT']) ? ':' . $_SERVER['SERVER_PORT'] : '')
. substr($_SERVER['SCRIPT_NAME'], 0, strrpos($_SERVER['SCRIPT_NAME'], '/')+1);
Please note that the $_SERVER array doesn't exist in PHP < 4.1.0. Try to replace $_SERVER by $HTTP_SERVER_VARS or $GLOBALS in this case.