How to make pdo run set names utf8 each time I connect, in zendframework?
Answer / Vikas Agarwal
To make PDO run SET NAMES UTF8 each time you connect in Zend Framework, follow these steps:n1. Create a new Db adapter that extends Zend_Db_Adapter_Pdo_Abstract.n2. Override the __construct() method and call the parent constructor with the necessary configuration settings.n3. Add the following code to set the charset:
```php
$this->_connection->exec('SET NAMES utf8');
```
| Is This Answer Correct ? | 0 Yes | 0 No |
How to check whether a form posted or not in the zend framework?
How to render view file from controller in zend framework?
How to include css from controller and view in zend
Why should we use framework?
Which class extend the zend model?
Writing a subquery using zend db?
Explain how routing works?
What is the zend file upload and element decorators?
how to remove all dtddwrappers and labels on zend form elements?
How to set 'selected' value in select box dropdown list?
What is zendauthentication?
How to install form component in zend framework?