Categories > TinyButStrong general >

Warning: htmlspecialchars()

The forum is closed. Please use Stack Overflow for submitting new questions. Use tags: tinybutstrong , opentbs
By: pfpro
Date: 2006-06-22
Time: 11:54

Warning: htmlspecialchars()

testing a project on 2 different apache servers

one is yelling:

Warning: htmlspecialchars(): charset `ANSI_X3.4-1968' not supported, assuming iso-8859-1 in /srv/www/htdocs/web1/html/controlcenter/inc/class/tbs_class.php on line 2172

got any ideas?
db related?

cheers
phil
By: Skrol29
Date: 2006-06-25
Time: 19:24

Re: Warning: htmlspecialchars()

htmlspecialchars() uses ISO-8859-1 charset by default, and so does TBS.
It seems that you are using ANSI_X3.4-1968 charset with TBS, but I didn't know such an error could be display by PHP.
By: vnnfree@yahoo.com
Date: 2009-06-22
Time: 09:56

Re: Warning: htmlspecialchars()

You can use
where display you content
[master_content;noerr;htmlconv=no;protect=no;onformat=tbs_str;]

and define a function

function tbs_str($FieldName,&$CurrRec) {
        $CurrRec = html_entity_decode($CurrRec,ENT_QUOTES);
        $CurrRec = str_replace('\"','"',str_replace("\'","'",$CurrRec));
        $CurrRec = str_replace('\\'.htmlspecialchars('"',ENT_QUOTES),htmlspecialchars('"',ENT_QUOTES),str_replace("\\".htmlspecialchars("'",ENT_QUOTES),htmlspecialchars("'",ENT_QUOTES),$CurrRec));
       
        $CurrRec = stripslashes($CurrRec);
    }