PHP Web Host - Quality Web Hosting For All PHP Applications Just Great Software
  Login or Register
 • Home • Downloads • Your Account • Forums • 

View next topic
View previous topic


Google
 
Web RavenPHPScripts (This Site)
Post new topic   Reply to topic
Author Message
steve_lemaster
Worker
Worker


Joined: Dec 26, 2006
Posts: 178

PostPosted: Mon Mar 26, 2007 9:35 pm Reply with quote Back to top

Can anyone tell me why forumsbackend.php displays a "Internet Explorer cannot display this feed"?

Watch it be something I am probably already staring at Mr. Green
View user's profile Send private message Send e-mail
jjh221
Worker
Worker


Joined: Dec 05, 2006
Posts: 178

PostPosted: Tue Mar 27, 2007 2:29 am Reply with quote Back to top

huh?
View user's profile Send private message
steve_lemaster
Worker
Worker


Joined: Dec 26, 2006
Posts: 178

PostPosted: Tue Mar 27, 2007 2:35 am Reply with quote Back to top

When I enter my url to my forumsbackend.php, it displays a "Internet Explorer cannot display this feed" page.
View user's profile Send private message Send e-mail
montego
Site Admin


Joined: Aug 29, 2004
Posts: 7456
Location: Arizona

PostPosted: Tue Mar 27, 2007 6:45 am Reply with quote Back to top

Use FireFox to open the same forum and you might actually get the error message. Man I hate MS... Sad

I suspect that there is something in your forum data causing issues, but we need to see the error to debug.
View user's profile Send private message Visit poster's website
steve_lemaster
Worker
Worker


Joined: Dec 26, 2006
Posts: 178

PostPosted: Tue Mar 27, 2007 10:39 am Reply with quote Back to top

Ok. Give me a minute.

The backend.php on my site works fine in M$
View user's profile Send private message Send e-mail
steve_lemaster
Worker
Worker


Joined: Dec 26, 2006
Posts: 178

PostPosted: Tue Mar 27, 2007 10:44 am Reply with quote Back to top

montego

My forumsbackend in FireFox shows up blank.
View user's profile Send private message Send e-mail
montego
Site Admin


Joined: Aug 29, 2004
Posts: 7456
Location: Arizona

PostPosted: Wed Mar 28, 2007 6:17 am Reply with quote Back to top

I have to admit that I am a bit confused over these conflicting posts:

steve_lemaster wrote:
When I enter my url to my forumsbackend.php, it displays a "Internet Explorer cannot display this feed" page.


and

Quote:
Ok. Give me a minute.

The backend.php on my site works fine in M$


But, I am not sure why I did not think of this sooner (sorry), but maybe try using a RSS validator, such as
Only registered users can see links on this board!
Get registered or login to the forums!
View user's profile Send private message Visit poster's website
steve_lemaster
Worker
Worker


Joined: Dec 26, 2006
Posts: 178

PostPosted: Wed Mar 28, 2007 8:38 am Reply with quote Back to top

montego wrote:
I have to admit that I am a bit confused over these conflicting posts:

steve_lemaster wrote:
When I enter my url to my forumsbackend.php, it displays a "Internet Explorer cannot display this feed" page.


and

Quote:
Ok. Give me a minute.

The backend.php on my site works fine in M$


But, I am not sure why I did not think of this sooner (sorry), but maybe try using a RSS validator, such as
Only registered users can see links on this board!
Get registered or login to the forums!


Don't understand the confusion, but anyway this is what i got.

column 66: XML parsing error: <unknown>:41:66: not well-formed (invalid token)

<title>Is the earth still recovering from the "little ice age&</title>


I fixed it, but apparently there are a host of other characters that the feed validator doesn't like. Oh well.
View user's profile Send private message Send e-mail
montego
Site Admin


Joined: Aug 29, 2004
Posts: 7456
Location: Arizona

PostPosted: Wed Mar 28, 2007 9:07 am Reply with quote Back to top

Confusion for me is that in the one post it references "internet Explorer" as not being able to read the feed and then in your other post you say it "works fine in M$"... never mind. It is not important.

Now we are on to something here with that clear error message. Thanks for posting that. I will have to open an issue on this as it is happening because of the chopping off of the &quot; character at the end. I have seen this happen before with another tool too.

Thanks for pointing this out.

The solution, everyone, is to either remove the double quotes in the forum TOPIC title. This is only an interim solution until we get a fix.
View user's profile Send private message Visit poster's website
steve_lemaster
Worker
Worker


Joined: Dec 26, 2006
Posts: 178

PostPosted: Wed Mar 28, 2007 9:55 am Reply with quote Back to top

montego wrote:
Confusion for me is that in the one post it references "internet Explorer" as not being able to read the feed and then in your other post you say it "works fine in M$"... never mind. It is not important.

Now we are on to something here with that clear error message. Thanks for posting that. I will have to open an issue on this as it is happening because of the chopping off of the &quot; character at the end. I have seen this happen before with another tool too.

Thanks for pointing this out.

The solution, everyone, is to either remove the double quotes in the forum TOPIC title. This is only an interim solution until we get a fix.


Understandable.

As you know there is the backend.php for the latest news feeds and there is the forumsbackend.php for the latest forum posts. Both FF and M$ can read the feed on the backend.php, however, they are having problems reading the forums feed.

Does that help? Now that you have cleared up the reason why, I can edit the topics in my forums Smile
View user's profile Send private message Send e-mail
montego
Site Admin


Joined: Aug 29, 2004
Posts: 7456
Location: Arizona

PostPosted: Wed Mar 28, 2007 10:26 am Reply with quote Back to top

Actually, I think I have a fix for this. Try replacing this:

return preg_replace(
'/&[A-Za-z]+;/',
' ',
strtr($string,$entity_to_decimal) );


With:

return preg_replace('/&([A-Za-z])/', '&\\1', strtr($string, $entity_to_decimal));

In my way of thinking, we have already converted all the entities that we care to convert and then what would it hurt to take any remaining "&" out there and just represent the "&" with its decimal equivalent.

If anyone can see a security risk with this please pipe up! Thanks!

Edited: Sorry, I already had changed the code to bring everything up on one line. I have modified this post back to what it should be in your forumsbackend.php
View user's profile Send private message Visit poster's website
steve_lemaster
Worker
Worker


Joined: Dec 26, 2006
Posts: 178

PostPosted: Wed Mar 28, 2007 10:31 am Reply with quote Back to top

Thanks!

Quote:
If anyone can see a security risk with this please pipe up! Thanks!


Sorry, I can't help you there. I'm still too much of a noob to know better Very Happy
View user's profile Send private message Send e-mail
steve_lemaster
Worker
Worker


Joined: Dec 26, 2006
Posts: 178

PostPosted: Wed Mar 28, 2007 10:37 am Reply with quote Back to top

montego wrote:
Actually, I think I have a fix for this. Try replacing this:

return preg_replace(
'/&[A-Za-z]+;/',
' ',
strtr($string,$entity_to_decimal) );


With:

return preg_replace('/&([A-Za-z])/', '&\\1', strtr($string, $entity_to_decimal));

In my way of thinking, we have already converted all the entities that we care to convert and then what would it hurt to take any remaining "&" out there and just represent the "&" with its decimal equivalent.

If anyone can see a security risk with this please pipe up! Thanks!

Edited: Sorry, I already had changed the code to bring everything up on one line. I have modified this post back to what it should be in your forumsbackend.php


That worked worship
View user's profile Send private message Send e-mail
Raven
Site Admin/Owner


Joined: Aug 27, 2002
Posts: 15210
Location: Kansas

PostPosted: Sun Apr 01, 2007 11:25 am Reply with quote Back to top

This is really odd as it validates at
Only registered users can see links on this board!
Get registered or login to the forums!


I also have checked the XML it for well-formness at
Only registered users can see links on this board!
Get registered or login to the forums!
and it validates.

I'm thinking more along the line that it may be the xml parser that you are using. Have you tried other parsers?
View user's profile Send private message Visit poster's website AIM Address Yahoo Messenger
montego
Site Admin


Joined: Aug 29, 2004
Posts: 7456
Location: Arizona

PostPosted: Sun Apr 01, 2007 11:58 am Reply with quote Back to top

Raven, to summarize the issue, it is caused by data. It can happen with Forums and News when the data is written to the database, if its htmlentitied (as phpBB appears to be doing), if the titles are long, they can get chopped off, leaving an "&" in the title without being a valid entity (so its not converted to its decimal equivalent).

For example, something like this entered into phpBB:

This is an example of a longer title, but do not "get hung up" on the exact length

In bbtopics, the title may end up as:

This is an example of a longer title, but do not &quot;get hung up&q

So, when forumsbackend.php picks this up, the first entity is handled properly, but the one that is "chopped off" is not.

Rather than trying to modify core phpBB and nuke, I put forth a fix to at least ensure the XML will end up being valid. To be honest, this is a 1% or less issue as the combination of long titles and quotes is a small percentage combination, hence why I decided to post a fix to the RSS feeds rather than trying to chase down how to keep the data from doing getting this way in the first place.

Priorities...
View user's profile Send private message Visit poster's website
Display posts from previous:       
Post new topic   Reply to topic

View next topic
View previous topic
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Forums ©
 

All logos and trademarks in this site are property of their respective owner.
The comments are property of their posters, all the rest © 2002-2008 by Raven
Proud to be listed at Lobo Links Web Directory

You can syndicate our news using the file xml

CSE HTML Validator Helped Clean up This Page! [Valid RSS] valid RSS 2.0 Valid robots.txt Stop Spam Harvesters, Join Project Honey Pot

Website engines core code is © copyright by PHP-Nuke but has been heavily patched and modified by myself and others.
PHP-Nuke is a free software released under the GNU/GPL.


:: fisubice phpbb2 style by Daz :: PHP-Nuke theme by www.nukemods.com ::

:: fisubice Theme Recoded To 100% W3C CSS & HTML 4.01 Transitional Compliance by Raven and 64bitguy ::

:: W3C CSS Compliance Validation :: W3C HTML 4.01 Transitional Compliance Validation ::

zerosum