Forums

Validating RSS, RDF (7 posts)

  1. Lowell
    Member
    Posted 9 years ago #

    I tried to syndicate my blog http://www.world.psiblog.com at Syndic8.com. I also tried to validate rss at http://feeds.archive.org/validator/
    But they both failed.
    Here's what I got from the validator:
    Sorry
    This feed does not validate.
    line 2, column 0: XML Parsing error: :2:0: xml declaration not at start of external entity [help]
    <?xml version="1.0" encoding="UTF-8"?><!-- generator="wordpress/0.71" -->
    ^
    Source: http://world.psiblog.com/b2rdf.php
    <?xml version="1.0" encoding="UTF-8"?><!-- generator="wordpress/0.71" -->
    I didn't see this topic covered anywhere. Can you suggest what is going wrong?
    Lowell

  2. Dougal Campbell
    Member
    Posted 9 years ago #

    Looks like there's a blank line at the beginning that needs to go.
    Check your b2rdf.php file and make sure that there aren't any blank lines before where it prints out the <?xml...> line.

  3. Lowell
    Member
    Posted 9 years ago #

    Here's what I've got in the file. I agree that the output seems to leave a blank line, but how to fix that?
    Lowell
    <?php /* These first lines are the first part of a CaféLog template.
    In every template you do, you got to copy them before the CaféLog 'loop' */
    $blog = 1; // enter your blog's ID
    header('Content-type: text/xml');
    include('blog.header.php');
    if (!isset($rss_language)) { $rss_language = 'en'; }
    if (!isset($rss_encoded_html)) { $rss_encoded_html = 0; }
    if (!isset($rss_excerpt_length) || ($rss_encoded_html == 1)) { $rss_excerpt_length = 0; }
    ?>
    <?php echo "<?xml version=\"1.0\"?".">"; ?>
    <!-- generator="wordpress/<?php echo $b2_version ?>" -->
    <rss version="0.92">

  4. Lowell
    Member
    Posted 9 years ago #

    I found the problem, or, at least I fixed the problem.
    I had moved my wordpress files from the wordpress directory on my server and into the main html section so that world.psiblog.com would show in the browser as index.php. For some reason this must have screwed up the rss files.
    I then simply re-uploaded the original rss and rdf files into the main html directory, and everything validates!

  5. Lowell
    Member
    Posted 9 years ago #

    Now I can't get http://www.psiblog.com/b2rss.php to work. It seems to leave a blank line at the beginning of the file, and so doesn't validate.
    Does anyone have an idea how to fix this? I've re-uploaded the original file that comes with the WordPress program, but it still doesn't work. I notice that there is a file called xmlrpc.php that is supposed to address this problem.

  6. Lowell
    Member
    Posted 9 years ago #

    Here's what the validator program says:
    Sorry
    This feed does not validate.
    line 2, column 0: XML Parsing error: :2:0: xml declaration not at start of external entity [help]
    <?xml version="1.0"?><!-- generator="wordpress/0.71" -->
    ^
    Source: http://psiblog.com/b2rss.php
    <?xml version="1.0"?><!-- generator="wordpress/0.71" -->
    <rss version="0.92">
    <channel>
    <title>PsiBlog</title>
    <link>http://psiblog.com/index.php</link>

  7. Dougal Campbell
    Member
    Posted 9 years ago #

    What release are you using? 0.71? 0.72b1? CVS?

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.