473,854 Members | 1,554 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

can't get my RSS to validate - Help!!

I'm running this page:

http://www.krubner.com/rss/page938.xml
through this validator:

http://rss.scripting.com/?url=http%3...%2Fpage938.xml
I can't get this page to validate. I'm getting two errors:

1. pubDate must be an RFC-822 date 9 9
2. Undefined rss element: item 12 7

The second one makes no sense to me. "item" is used in all the
examples they give for .91 RSS, so why is the validator giving me
grief?
Jul 20 '05 #1
9 1965
lawrence wrote:
I'm running this page:

http://www.krubner.com/rss/page938.xml
through this validator:

http://rss.scripting.com/?url=http%3...bner.com%2Frss 2Fpage938.xml

I can't get this page to validate. I'm getting two errors:

1. pubDate must be an RFC-822 date 9 9
2. Undefined rss element: item 12 7

The second one makes no sense to me. "item" is used in all the
examples they give for .91 RSS, so why is the validator giving me
grief?


I don't know rss, but your items are direct children of rss, and
according to the dtd, the only valid child element for rss is channel
and the only valid parent element for item is also channel.

Jul 20 '05 #2
lk******@geocit ies.com (lawrence) wrote in message news:<da******* *************** ****@posting.go ogle.com>...
I'm running this page:

http://www.krubner.com/rss/page938.xml

through this validator:

http://rss.scripting.com/?url=http%3...%2Fpage938.xml
I'd believe George Bush before I trusted the accuracy of a validator
from scripting.com -- and for similar reasons; both are always "right"
(i.e. not obvious enough to clearly catch them at it) but they'll
cheerfully redefine black as white to push their own agendas.

I can't get this page to validate. I'm getting two errors:

1. pubDate must be an RFC-822 date 9 9
Your <pubDate> has no content. The whole element is optional, but if
you're going to use it, you have to give it some content.
2. Undefined rss element: item 12 7


You need to have <item> as a child of <channel>. This 0.91 feed has it
as a child of <rss> (which is where RSS 1.0 places it, so that might
have caused some confusion)

I wouldn't suggest 0.91 either, as a format for new work. 1.0 is best
(a hobby horse of mine), but go to 0.92 as a minimum.
Jul 20 '05 #3
lk******@geocit ies.com (lawrence) wrote in message news:<da******* *************** ****@posting.go ogle.com>...
I'm running this page:

http://www.krubner.com/rss/page938.xml
through this validator:

http://rss.scripting.com/?url=http%3...%2Fpage938.xml
I can't get this page to validate. I'm getting two errors:

1. pubDate must be an RFC-822 date 9 9
2. Undefined rss element: item 12 7

The second one makes no sense to me. "item" is used in all the
examples they give for .91 RSS, so why is the validator giving me
grief?

Thanks very much. I rearranged things and got it to validate, using
the validator from scripting.com.

However, it still fails validation at
http://feeds.archive.org/validator/

The problem is "bad characters". I'm not sure how to start to debug
that. What is the first thing I should look for?

I wrote the 0.91 script (a PHP script) first because I assumed it
would be easy. I figured once I worked out the troubles at 0.91, I
could move up and do scripts for 1.0 and 2.0. The fact that I'm having
trouble even at the 0.91 level makes me happy that I didn't jump
straight to the 1.0 or 2.0 level.
Jul 20 '05 #4
lawrence wrote:
I'm running this page:

http://www.krubner.com/rss/page938.xml

However, it still fails validation at
http://feeds.archive.org/validator/

The problem is "bad characters". I'm not sure how to start to debug
that. What is the first thing I should look for?


Did you change anything? I get "This is a valid RSS feed." with <>
http://feeds.archive.o rg/validator/>.

--
Johannes Koch
In te domine speravi; non confundar in aeternum.
(Te Deum, 4th cent.)
Jul 20 '05 #5
> However, it still fails validation at
http://feeds.archive.org/validator/
The version this morning seems OK. I suggest you keep an archive of
these bad feeds under static URLs, so that we can more easily see the
problems.
The problem is "bad characters". I'm not sure how to start to debug
that. What is the first thing I should look for?
Most likely thing is the use of HTML entities (like &eacute; ) that
aren't valid because RSS is an XML protocol and doesn't recognise
these HTML-defined entities. A _very_ common error in RSS feeds.

I wrote the 0.91 script (a PHP script) first because I assumed it
would be easy.


I have to ask why anyone needs to write RSS scripts these days ?
(Although I spent yesterday doing it myself). There are very many
already out there, and it's a rare situation that really needs
something written from scratch.

I suggest that you learn a bit more detailed XML (entities for one
thing, namespaces for another) and learn how to read a formal DTD.
It's one thing to make a feed work once during testing, but quite
another to make a reliable feed that handles all the data it will meet
over its lifetime. Sadly RSS tools suffer badly from this - they run
for a week, then crash when they meet their first accented European
character. To get a reliable feed, you really do need to know how to
_understand_ the specification, not just match up one example.

As to the versions, then I'd support 0.92 and 1.0 1.0 is best, 0.92
solves compatibility issues for some older or simpler aggregators. 2.0
is pointless.

You don't need to understand Dublin Core to use RSS 1.0, but you will
do if you want to really use it. Worth the effort of studying it
anyway (Learning Dublin Core is vastly more useful than learning RSS
anyway)

Hang in there - RSS versions don't really vary that much between
themselves.
Jul 20 '05 #6
di*****@codesmi ths.com (Andy Dingley) wrote in message news:<28******* *************** ****@posting.go ogle.com>...
However, it still fails validation at
http://feeds.archive.org/validator/


The version this morning seems OK. I suggest you keep an archive of
these bad feeds under static URLs, so that we can more easily see the
problems.
The problem is "bad characters". I'm not sure how to start to debug
that. What is the first thing I should look for?


Most likely thing is the use of HTML entities (like &eacute; ) that
aren't valid because RSS is an XML protocol and doesn't recognise
these HTML-defined entities. A _very_ common error in RSS feeds.


I'm stumped when I think of all the possible user inputs that can mess
up an RSS feed. Myself and a friend have been working on some weblog
software for a year now - the weblog entries show up in the RSS feed.
Lots and lots of problems come up - people might copy and paste
something from Word in their weblog and then get a Windows character
that is not in the defined char set for the RSS feed. How to protect
against that. Or people can, as you say, add in some HTML entities, or
sometimes the software does that automatically.

It's true that I could write filters for each possible problem as it
comes up, but it seems like it would take a mountain of code and there
would never be an end to it - after I figure out how to convert
unexpected European accented characters, then I'd have all the Asian
alphabets to work on.

I guess I'm asking if there is an easy, elegant way to convert a set
of characters to some particular character set. I don't know of any
myself. What strategies have other programmers used when tackling this
problem?
Jul 20 '05 #7
di*****@codesmi ths.com (Andy Dingley) wrote in message >
I have to ask why anyone needs to write RSS scripts these days ?
(Although I spent yesterday doing it myself). There are very many
already out there, and it's a rare situation that really needs
something written from scratch.
I think that is a fair question. Part of the answer would be, I guess,
we want to be able to assert that our weblog software is "complete" in
some sense. Without RSS, it is not complete. The other aspect of it,
call it an institutional mission, is that we want to donate all our
code to the public domain. That means we often have to do things from
scratch, because other we might use is copyrighted. There is a lot of
good code under the GPL, but the GPL is too restrictive for our
purposes.

I suggest that you learn a bit more detailed XML (entities for one
thing, namespaces for another) and learn how to read a formal DTD.
It's one thing to make a feed work once during testing, but quite
another to make a reliable feed that handles all the data it will meet
over its lifetime.


I really would love to learn more about XML and I've bought a bunch
books from O'Reilly. Sadly, I'm stretched a little thin. Me and some
friends have been working on a content management system and I've had
to learn a lot about a lot of different stuff, and I haven't had the
chance to become very good at anything. I'd like to know more about
XML, XHTML, Apache, CSS 2.0, RSS, Linux, Windows XP, mime types,
character encodings, SOAP, Java, web services, Flash, PostGreSql,
Swing, MySql, encryption and a whole lot more. It's all just too much.
My hope, at this point, is they'll come a point when the basic
abilities of our CMS are stable enough that I can go over it again and
go deeper into certain areas when my knowledge is better. That, or
maybe our project can pick up some programmers who are more talented
than I.

We're giving away our (still quite buggy) software here:

http://www.publicdomainsoftware.org/
Jul 20 '05 #8
lk******@geocit ies.com (lawrence) wrote in message news:<da******* *************** ****@posting.go ogle.com>...
I'm stumped when I think of all the possible user inputs that can mess
up an RSS feed.
Can't be done. Never was possible - users are just too inventive.

Instead, look at it the other way. Find the set of all things that are
_valid_ RSS and exclude anything else. This is a smaller set than the
invalid stuff, and it's better documented. If you _only_ allow the
valid sequences, then you have implicitly forbidden all the invalid
stuff.

Definitely read this
http://diveintomark.org/archives/200...compatible-rss

It's true that I could write filters for each possible problem as it
comes up,


No, you can't. You might possibly manage to do it for one day, but
there will always be something new coming along tomorrow. Take it the
other way.
Jul 20 '05 #9
di*****@codesmi ths.com (Andy Dingley) wrote in message news:<28******* *************** ****@posting.go ogle.com>...
lk******@geocit ies.com (lawrence) wrote in message news:<da******* *************** ****@posting.go ogle.com>...
I'm stumped when I think of all the possible user inputs that can mess
up an RSS feed.


Can't be done. Never was possible - users are just too inventive.

Instead, look at it the other way. Find the set of all things that are
_valid_ RSS and exclude anything else. This is a smaller set than the
invalid stuff, and it's better documented. If you _only_ allow the
valid sequences, then you have implicitly forbidden all the invalid
stuff.

Definitely read this
http://diveintomark.org/archives/200...compatible-rss


Thanks for the link to the Mark Pilgrim article. Despite the obvious
anti-Dave Winer bias in the article, I thought it was very good and
very informative.

I like your suggested style for moving forward but don't understand
how to do it. Should I take an input (when a user posts) and take
every character and put it into an array and then test it against an
array full of those character's that are allowed? That seems
cumbersome, though it only happens when the user inputs stuff, so
being cumbersome at that point isn't lethal. But is there a more
graceful way to validate the input?
Jul 20 '05 #10

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
2964
by: Pato Secruza | last post by:
Hi everyone! I have a really frustrating error and need help. I’m trying to do a function that gets the properties and names of the fields in a MS Access database using ASP. I haven’t programmed in a while so I’m quite lost. Once I have the my database structure I will insert the corresponding fields from a web form but the database is huge and I want to be able to change the database and form without changing the ASP code all the
0
1496
by: Shaggyh | last post by:
hi im needing help with a program im writing to do subnetting i was on before about it and i got some help. the code below wont work for me and i cant think of why not. i was wondering if anyone out there can help, even come up with a better way of doing this.. i have 2 files.. here is my first file.. // a library assembly i.e. dll
9
2235
by: AFN | last post by:
I was just dropped into someone else's code (isn't that always so fun?). I can't figure out why a custom validation control's server event function is executing. There is nothing (that I see) in page_load, or elsewhere, that says page.validate, no control says "causesvalidation=true", and the AutoEventWireup is set to false. So I would think that the control's server event function would NOT execute, but it does execute right after...
8
1340
by: greg.gottfried | last post by:
I am very new to java script. I am wanting to validate a form and I cant seem to get one validation to work. The first two work, but the thrid I want to have a max length of 30 and I cant ssem to figure out how to do that. Please help! var msg = ""; if(document.jobOpening.jobCity.value == ""){ msg = msg + "Please provide a Job City before submitting the form."; alert(msg); document.jobOpening.jobCity.focus();
2
1346
by: pyropyro78 | last post by:
hey i know this is asking alot but i cant figure out how to get my site to validate if any1 here has some spare time after reading this post please tweek my html or something in a word and tell me how to get http://fightersguildss.tripod.com/index.htm to validate properly. i will do almost anything for this help. thank you all for you assistance ahead of time. if you can do the index page i will try to study off that to get rest to work. also...
1
2582
by: vbnewb | last post by:
Hey All, I am new to the forums. Have been reading a bit here on some very useful tips and tutorials here. I am familiar with the basics of Access (tables , queries, forms,) but am such a newb at macros and the VB side of the application. I have been put to the task of building a tool in which will validate when one user has transferred an clients casefile to another user. as this is a windows NT environment i am using the NT usernames...
11
1798
by: shror | last post by:
Hi every body, Please I need your help solving my php mail() function problem that the code is appearing in the view source and I dont know whats the problem where I am using another page tto test the php and its executed very nice The page have php code viewed : http://beachtoursegypt.com/booking-form.htm where after submitting the form the data are sent to the confirmation age where the php script lies there and its not executed
2
1119
by: Andy B | last post by:
I have a detailsView (replaced the formview with it) thinking it would help me fix my control access in a formview problem. Well, I don't think .net knows how to count. Here is what I have: I am trying to display the value of a certain cell in a label control. Say, NewsId for my example. In this example, NewsId should be 14. I took this line and used it to find out how many rows there were: DateConfirmLabel.Text =...
2
6364
by: embz | last post by:
this post concerns three pages. 1. this page: http://www.katherine-designs.com/sendemail.php i get the following errors: a lot of it seems to deal with the PHP code i inserted to the page. as my PHP skills are close to nil, i'm wary about fiddling with it myself. =\ 2. now this page: http://www.katherine-designs.com/contact.php
0
9751
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
11024
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10367
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
9512
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7914
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
7079
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5940
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4557
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
4153
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.