control the output of third party content

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
gentleone
Forum Newbie
Posts: 2
Joined: Fri Nov 06, 2009 4:28 am

control the output of third party content

Post by gentleone »

I'm struggling with getting my PHP document valid XHTML 1.0 Strict.

I use a PHP snippet to parse RSS feeds, but if there is a normal "&" in the feed instead of the ampersand version "&" then I get a validation output error.

So my question is, can I control or convert somehow the output from the RSS feeds so that it would change the "&" in the ampersand version?

Perhaps a dumb question, but I'll never know unless I ask. :)
gentleone
Forum Newbie
Posts: 2
Joined: Fri Nov 06, 2009 4:28 am

Re: control the output of third party content

Post by gentleone »

Problem solved!

I've added

Code: Select all

.htmlentities()
to

Code: Select all

.$val->title).
Post Reply