Database_Exception [ 8192 ]: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead My project is working fine in window+php 5.4, but for ubuntu+php5.5, it is creating problem. Any suggestions..?
Asked
Active
Viewed 4,375 times
2 Answers
4
Look here: http://php.net/manual/en/migration55.deprecated.php
MySQL extension is deprecated in php 5.5. You are probably using MySQL extension, it is time to change it to MySQLi or PDO as error is telling you.
That should be helpfull: Kohana 3.3 not using MySQLi driver
You can use: https://github.com/Azuka/Kohana-Database-MySQLi
Just put that class in you modules.
MODPATH/mysqli
Enable mysqli module in boostrap.php:
'mysqli' => MODPATH.'mysqli',
Change in you database.php config file:
'type' => 'mysql',
to
'type' => 'mysqli',
-
http://mastersoftwaretechnologies.com/kohana-blog/index.php/article This is where I'm working. I changed mysql type to mysqli. – deepak Aug 11 '14 at 11:01
-
Thanks for reply.. I have enabled the mysqli module in bootstrap.php by adding 'mysqli' => MODPATH.'mysqli' and added the classes folder to the modules folder. Whats next..? – deepak Aug 11 '14 at 11:28
-
You have error: Kohana_Exception [ 0 ]: Attempted to load an invalid or missing module 'mysqli' at 'MODPATH/mysqli' Check if you locaed mysqli folder in right place. – Grzesiek Aug 11 '14 at 11:35
-
In which folder I have to locate it. – deepak Aug 11 '14 at 11:40
-
1if you will unzip downloaded file you will have folder with will contain classes folder, that classes folder you have to put to: MODPATH/mysqli/, then it will work. after this just change database config as I wrote in first answer. – Grzesiek Aug 11 '14 at 11:44
-
Its Working.. Thanks for your great support. – deepak Aug 11 '14 at 11:47
-1
After you do what is written above correct in install.php
<?php if (function_exists('mysql_connect')): ?>
To
<?php if (function_exists('mysqli_connect')): ?>

Striped
- 2,544
- 3
- 25
- 31