htmlspecialchars Questions
4
Solved
I know there are other ways of of escaping only single quotes (such as this answer), but it appears to me that there should be a way using htmlspecialchars().
According to the manual, it sho...
Sebaceous asked 14/5, 2012 at 21:3
4
Solved
I have trouble transforming a string to lowercase with the tolower() function in C++. With normal strings, it works as expected, however special characters are not converted successfully.
How I us...
Depew asked 14/3, 2017 at 16:27
4
Solved
So i'm trying to code a simple website form. But it has this htmlspecialchars error.
I've tried to make {{ $message }} but it didn't work. has the same error.
this is my controller :
<?php
n...
Rivas asked 12/2, 2019 at 8:2
8
Is there a similar or equivalent function in Python to the PHP function htmlspecialchars()? The closest thing I've found so far is htmlentitydefs.entitydefs().
Bandung asked 31/5, 2009 at 5:58
10
Solved
I've seen this asked several times, but not with a good resolution. I have the following string:
$string = "<p>Résumé</p>";
I want to print or echo the string, but the output will re...
Misreport asked 2/10, 2012 at 22:3
5
Solved
Of course this has been asked before and have searched for solutions, all which have not worked thus far. I want to change out the TM symbol and the ampersand to their html equivelents by using htm...
Urita asked 4/4, 2013 at 15:49
2
I'm doing a .php RSS generator and I have a problem trying to get data from my database in this line:
<description><![CDATA[<?=htmlspecialchars(utf8_substr($row['texto'], 0, 100), ENT_...
Saberio asked 18/6, 2012 at 18:37
6
Here is the line of code I have which works great:
$content = htmlspecialchars($_POST['content'], ENT_QUOTES);
But what I would like to do is allow only certain types of HTML code to pass throug...
Cusack asked 10/10, 2012 at 12:51
4
Solved
I need to replace all & with with &amp; in a string like this:
Übung 1: Ü & Ä
or in html
&Uuml;bung 1: &Uuml; & &Auml;
Like you see htmlspecialchars in the string ...
Undine asked 4/1, 2013 at 8:51
4
Solved
Hi
I was wondering when is the appropriate place to use htmlspecialchars(). Is it before inserting data to database or when retrieving them from the database?
Stanfield asked 3/2, 2011 at 3:12
3
Solved
I a using the the HTML encode special characters in Sublime text to convert all the special character into their HTML code. I have a lot of accented characters in different parts of the file. So, i...
Kirov asked 20/12, 2012 at 16:3
1
Solved
I have staff.php page which contains staff's name,position and detail.When user would need to edit staff info,they would be send to edit.php page.edit.php page show name and title on text field and...
Ranunculaceous asked 18/3, 2015 at 0:11
5
Basically on displaying data from MySQL database I have a htmlspecialchars() function below that should convert single and double quotes to their safe entity(s). The problem I'm having is on viewin...
Education asked 18/1, 2011 at 10:1
6
Solved
I am getting this error in my local site.
Warning (2): htmlspecialchars(): Invalid multibyte sequence in argument in [/var/www/html/cake/basics.php, line 207]
Does anyone knows, what is the prob...
Mccomb asked 27/9, 2010 at 12:52
3
Solved
I'm developing a dependent select script using jQuery, PHP and JSON as the response.
Everything goes well except for using special characters like French ones (é , è , à...)
if I pre-encode them ...
Pellegrino asked 2/9, 2011 at 13:58
1
Solved
There are a lot of questions and documentation about converting HTML entities and special characters to UTF8 text in PHP. And also there is the PHP documentation itself, such as this htmlspecialcha...
Teratogenic asked 18/8, 2014 at 21:9
1
Solved
I am a little confused on this. I have been reading about htmlspecialchars() and I am planning to use this for the textareas POST to prevent XSS attack. I understand that usually htmlspecialchars()...
Laity asked 6/1, 2014 at 20:58
3
I'm currently working on a website, where users can write articles with few format possibilities (like bold, italic, list...). I'm using a framework: CodeIgniter.
I'm a beginner, and I've heard so...
Pyo asked 19/6, 2013 at 9:55
1
I have a php 5.4/mysql website with 5 million hits per day, running on a linux server with nginx and php-fpm. Database is located on a separate server.
I've noticed, that at peak times, my webserv...
Killy asked 17/4, 2013 at 12:32
1
Solved
Since php 5.4 html_entity_decode introduces four new flags, with a minimal explanation
ENT_HTML401 Handle code as HTML 4.01.
ENT_XML1 Handle code as XML 1.
ENT_XHTML Handle code as XHTML.
ENT_HTML...
Antibody asked 6/12, 2012 at 14:9
4
Solved
this may seem like a simple problem but I couldn't find it in the archives.
how does one reverse the effects of htmlspecialchars?
I tried something like this:
$trans_tbl = get_html_translation_t...
Answerable asked 29/6, 2012 at 6:45
1
Using both htmlspecialchars and htmlentities is causing blank outputs from items such as a ™ symbol and even single ' quotes. Obviously, this is absolutely useless, however outputting the data with...
Globule asked 26/6, 2012 at 15:11
1
Solved
I encountered a particular string (it's not completely printable, but you can see it below) that causes a htmlspecialchars() to return a zero-length string. Is there any way this can be fixed?
$St...
Astrobiology asked 29/7, 2012 at 0:56
1
Solved
I am trying to create a simple method which accepts the parameters for htmlspecialchars. Although I am getting PHP notice:
Use of undefined constant ENT_HTML5 - assumed 'ENT_HTML5'
Any ideas ...
Deannadeanne asked 17/7, 2012 at 13:13
3
Solved
I want to sent some html special character to text field and then later use javascript to get it back in its original format: like if I sent "&pi", it will shows "π" on the text input, and when...
Noma asked 17/7, 2012 at 8:6
1 Next >
© 2022 - 2024 — McMap. All rights reserved.