Welcome Guest, Not a member yet? Register   Sign In
Auto decodeing htmlspecialhars on output.
#1

The CI db library automatically converts my data into htmlspecialchars. I want it to be automatically decoded during output. Is it possible? I don't want to end up changing every $row->value to htmlspecialchars_decode($row->value).
Reply
#2

The CI db library doesn't do what you're saying it does.
Reply
#3

(10-09-2015, 02:20 AM)Narf Wrote: The CI db library doesn't do what you're saying it does.

It converts all my input and automatically converts it to html special chars if I user insert or update method of db library.
On https://www.codeigniter.com/userguide3/d...ilder.html, it says


Quote:It also allows for safer queries, since the values are escaped automatically by the system.

So if I use these methods and have a look at my db it is converting it to htmlspecialchars to escape properly.
What I want is somehow these htmlspecialchars should be converted back to normal text while retrieving back.

Thanks in advance
Reply
#4

Sorry, for all the trouble. I was using set_value() to get the values. I did not know that it was converting input into htmlspecialchars. Now switching back to input->post() fixed things
Reply




Theme © iAndrew 2016 - Forum software by © MyBB