[mythtv] mythweb translation problem with HTML entities (was Re: [mythtv-commits] mythtv commit: r8618 - in trunk/mythplugins/mythweb by xris)

Petr Stehlik pstehlik at sophics.cz
Tue Jan 17 21:23:59 UTC 2006


Petr Stehlik píše v Út 17. 01. 2006 v 22:20 +0100:
> > > I don't know why it happens. I actually don't know why the strings are
> > > translated to HTML entities at all. Any reason? I admit I don't know
> > > PHP..
> > 
> > Just means those htmlentities calls need to be made UTF-8 aware.  Really 
> > wish php supported function overloading.  Guess I should just write a 
> > new function that does the htmlentities($strung, ENT_COMPAT, 'UTF-8') 
> > automatically so I don't have to type that extra stuff every time.
> > 
> > As for the "why"...  mainly because I just don't trust user input (esp. 
> > data from the listing providers).
> 
> I don't understand a word.

Ah, I just grep'ed through the mythweb and can see the function. Will
try to figure out why it's there at all.

The reason you mention (don't trust) seems to be completely invalid as
the listing data is not affected by the entities.

Petr




More information about the mythtv-dev mailing list