• rockster

    (@rockster)


    Hi folks,

    Just installed wp1.5 on a hosted account (I can’t install modules). I got the error that goes something along the lines of “your PHP installation appears to be missing the MySQL extension”…

    When I dug around in the forums, I found this error was coming from this line in the file wp-settings.php:
    ———-
    if ( !extension_loaded(‘mysql’) )
    die( ‘Your PHP installation appears to be missing the MySQL which is required for WordPress.’ )
    ———-
    I’m not a coder, but I figured that the command “die” meant to stop processing the script because my host didn’t have mysql extensions… they claimed they did have them… so I used the following (nabbed from a php help site somewhere!) cut it, pasted this, saved it, ran it:

    <?php

    // Show all information, defaults to INFO_ALL
    phpinfo();

    // Show just the module information.
    // phpinfo(8) yields identical results.
    phpinfo(INFO_MODULES);

    ?>

    And… LO and BEHOLD… my host had disabled the “extension_loaded” thingy, command, whatever! SO… it WAS NOT mysql that caused the installation to die… it was extension_loaded!! And extension_loaded was clearly put in there to prevent install errors (or troubleshoot) for those w/out mysql extensions.

    I believe they call this irony… Anyway… I hope this helps. (I deleted that line from wp-settings.php and I’m up & running, baby!)

Viewing 4 replies - 1 through 4 (of 4 total)
  • laurieslegends

    (@laurieslegends)

    Hi,

    Did you run this as a separate php file, if so what directory did you put it in? If not did you replace this in the same file mentioned abouve in place of the die statement. I am not a coder either, just a “teach it to myself” by trial and error person. :o)

    Thread Starter rockster

    (@rockster)

    All I did was remove the offending lines in wp-settings.php and resaved it as is since I know that I have the right extensions, no need for that bit of code.

    I also found and fixed the exact same problem. The same line in the script doesn’t work on my host either (GoDaddy Windows hosting). Look at my last post in this thread:

    https://www.ads-software.com/support/topic.php?id=14126

    to see a few more hints on exactly what to do, and a modification that will let you print out all the extensions that are supported on your host…

    hi, all.
    I have a problem when I use Zend to develop. WordPress Works all right on IE, but when I run wordpress on Zend Studio, it turns out
    “Your PHP installation appears to be missing the MySQL which is required for WordPress.”

    ————–

    I have tried this in Zend Studio
    //—-
    print_r(get_loaded_extensions());

    if ( !extension_loaded(‘mysql’) )
    die( ‘Your PHP installation appears to be missing the MySQL which is required for WordPress.’ );
    //—
    and the results are these:

    Array
    (
    [0] => bcmath
    [1] => calendar
    [2] => com_dotnet
    [3] => ctype
    [4] => ftp
    [5] => iconv
    [6] => odbc
    [7] => pcre
    [8] => session
    [9] => SPL
    [10] => SQLite
    [11] => standard
    [12] => tokenizer
    [13] => zlib
    [14] => libxml
    [15] => dom
    [16] => SimpleXML
    [17] => wddx
    [18] => xml
    [19] => Zend Debugger
    )

    It seems that Zend Studio dosen’t load the extensions like “mysql”(I have enabled “extension=php_mysql.dll” in php.ini ). help, thank you!

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Missing MySQL Error – a possible fix for those who are on hosted accts’ is closed to new replies.