Friday, January 4, 2019

php - cakephp page title with utf8 encoding

in cakephp website the page title is not replacing its special characters to corresponded utf encoded characters.To make sure i have already tried:




  • converted database to utf8_general_ci collation

  • first line of bootstrap.php: header('Content-Type: text/html; charset=utf-8');


  • core.php: Configure::write('App.encoding', 'UTF-8');

  • in database.php: 'encoding' => 'utf8' while creating database connection

  • in ajax.ctp (my site is using this layout): echo $this->Html->charset('UTF-8');

  • in header.ctp of the file for which i want to set the title: echo $title_for_layout; enclosed within the title tag.



I've tried a lot and instead doing all of this ,page title is still showing special characters.Can anyone tell me what i'm missing or anything else?

No comments:

Post a Comment

plot explanation - Why did Peaches' mom hang on the tree? - Movies & TV

In the middle of the movie Ice Age: Continental Drift Peaches' mom asked Peaches to go to sleep. Then, she hung on the tree. This parti...