[wp-hackers] WorPress dies silently without MySQL PHP extention

Ozh ozh at planetozh.com
Fri Dec 4 11:43:04 UTC 2009


My guess is that it *is* OK, to prevent an ugly notice and just
display the pretty, maybe custom, error message using wp_die()
instead.

On Fri, Dec 4, 2009 at 12:25 PM, scribu <scribu at gmail.com> wrote:
> No, it's not ok. Should probably remove the @ before the function.
>
> I thought you got a "Can't connect to the database" warning page when that
> happens.
>
> Btw, WordPress doesn't guarantee compatibility with any DB other than MySQL.
>
>
> On Fri, Dec 4, 2009 at 3:44 AM, Vlad GURDIGA <gurdiga at gmail.com> wrote:
>
>> Hello!
>>
>> When there is no MySQL PHP extension installed, for example when you
>> have WordPress working on an SQLite DB instead of MySQL, wpdb
>> constructor dies silently trying to
>>
>> $this->dbh = @mysql_connect($dbhost, $dbuser, $dbpassword, true);
>>
>> Is that OK?
>> _______________________________________________
>> wp-hackers mailing list
>> wp-hackers at lists.automattic.com
>> http://lists.automattic.com/mailman/listinfo/wp-hackers
>>
>
>
>
> --
> http://scribu.net
> _______________________________________________
> wp-hackers mailing list
> wp-hackers at lists.automattic.com
> http://lists.automattic.com/mailman/listinfo/wp-hackers
>



-- 
http://planetOzh.com ~ Blog and WordPress Stuff
http://FrenchFragFactory.net ~ Daily Quake News


More information about the wp-hackers mailing list