php - How do I avoid html entities in the view in CakePHP? -


so data being saved in mysql actual apostrophes etc. when cakephp spits out in view this: if you're on page

i don't want have htmlspecialchars_decode() on every string in app. there cakephp solution kind of issue?

here echo of text:

<?php echo $this->text->autolinkurls(h($item['item']['post_comment'])); ?>

here field info post_comment: post_comment info

and here form field it's being submitted as:

echo $this->form->textarea('post_comment', array('label' => false, 'placeholder' => 'ask question or post link', 'rows' => '3', 'class'=> 'u-full-width')); 

edit: what's stranger - in other parts of app, apostrophes come out fine.

autolinkurls takes options same link(). help. try -

<?php echo $this->text->autolinkurls(h($item['item']['post_comment']), array('escape' => false)); ?> 

Comments