WordPress.org

Ready to get started?Download WordPress

Forums

This problem needs to be resolved. (37 posts)

  1. DJ Rg
    Member
    Posted 9 years ago #

    XML Parsing Error: xml processing instruction not at start of external entity
    Location: http://www.splashhall.org/blog/wp-rss2.php
    Line Number 2, Column 1:
    <?xml version="1.0" encoding="utf-8"?>
    ^
    why am i getting this error? and how do i fix?
    this has gone unanswered for over 36 hours ..its your code ..please help?
    podz started to help then just ignored me, its your code that is the problem please help fix it..
    http://wordpress.org/support/3/12336

  2. Brak
    Member
    Posted 9 years ago #

    You have look what's being spit out on line 1. <?xml... needs to be line #1. Not #2.

  3. DJ Rg
    Member
    Posted 9 years ago #

    could you rewrite that portion ..assuming you mean this part?
    <?php if (!isset($feed)) {
    $blog = 1;
    $doing_rss = 1;
    require('wp-blog-header.php');
    }
    $more = 1;
    $charset = get_settings('blog_charset');
    if (!$charset) $charset = 'UTF-8';
    header('Content-type: text/xml', true);?><?php echo '<?xml version="1.0" encoding="' . $charset . '"?'.'>'; ?>

    part of my problem is i never have worked with php...
    thank ya kindly..

  4. Joni
    Member
    Posted 9 years ago #

    Try downloading that file, and checking that there is not a blank line at the top of the file contents.

    What's hard to understand about the advice Podz gave you above? Do you have a text or HTML editor or plain old Notepad where you can view the file in question to see if indeed there is a blank line there? I hardly consider his advice "ignoring you."

  5. Brak
    Member
    Posted 9 years ago #

    Do you have a blank line before that first <?php I'd be willing to bet that's your problem. It's either there or you've edited wp-blog-header.php somewhere.

  6. Mark (podz)
    Support Maven
    Posted 9 years ago #

    "podz started to help then just ignored me"
    Cheers.
    My daughter, who is 10, asked if I would go out with her for a bike ride. Now, where exactly should my priorities lie ?

  7. DJ Rg
    Member
    Posted 9 years ago #

    well.. my apologies to podz and all concern ..frustration had set in ..which i think ya'll can see and understand....
    how about we move forward and fix this problem ..white space has been checked and there is none ..i havent altered any files ..i have only done/do exactly as podz advises...
    how about someone paste their code for the rss file here and i will copy it to mine ..we can work forward from here... then, yes?
    thank you

  8. Anonymous
    Unregistered
    Posted 9 years ago #

    Alright, assuming you've calmed down a bit. I will throw in a link (but it come with my 2 cents). I am having beaucoups more problems than you and though your problem is not one of them, neither is a fault of the code.
    wp-rss2 has not changed significantly in the CVS so you can back up yours and download a copy from there:
    CVS wp-rss2.php
    A dime to a donut says we will have to track the problem down somewhere else, though.

  9. Beel
    Member
    Posted 9 years ago #

    'twas me above

  10. DJ Rg
    Member
    Posted 9 years ago #

    ok ..thx... getting the same error ..also get the error on commentsRSS...
    the error says ..external entity ..what external entity?
    maybe something to note both FeedBurner and FeedValidater say the same thing..
    http://feedvalidator.org/check.cgi?url=http%3A%2F%2Fsplashhall.org%2Fblog%2Fwp-rss2.php
    one other note ...it does work in IE ..but whats important is FireFox and places like FeedBurner..
    what do we try next..?

  11. Anonymous
    Unregistered
    Posted 9 years ago #

    caferg, every page on your new blog has a blank line as line 1, this will cause validation problems with all the feeds, rss, rss2 and atom. currently the index.php validates but I think that is a mistake as it claims to be xhtml and xhtml is suposed to be valid xml and having a blank line is not valid xml as you have already seen
    you have more problems than just a broken rss2 feed, time to start hunting it down.

  12. DJ Rg
    Member
    Posted 9 years ago #

    i been looking at other pages, though a programmer i am NOT... as with the RSS file there is now way, either through notpad or WP template CP, for me to move up a line ..there just isnt another line to move anything to..
    i did find this in the xmlrpc file ..indicating this is not an isolated problem ..and if someone was to ask the proper programmers ..there would be a fix..
    <?php
    [strong]# fix for mozBlog and other cases where
    <?xml' isn't on the very first line
    $HTTP_RAW_POST_DATA = trim($HTTP_RAW_POST_DATA);[/strong]
    include('wp-config.php');
    include_once (ABSPATH . WPINC . '/class-xmlrpc.php');
    include_once (ABSPATH . WPINC . '/class-xmlrpcs.php');
    // Turn off all warnings and errors.
    error_reporting(0);
    $post_default_title = ""; // posts submitted via the xmlrpc interface get that title
    $post_default_category = 1; // posts submitted via the xmlrpc interface go into that category

  13. DJ Rg
    Member
    Posted 9 years ago #

    though that says it is a fix, it isnt helping me?

  14. Anonymous
    Unregistered
    Posted 9 years ago #

    that is a fix specific to the xmlrpc file, you have a different problem that needs fixing.
    something about your server configuration is adding a blank line to the beginning of your pages.
    you do NOT have any blank lines in the scripts something else is adding them to the OUTPUT only.

  15. DJ Rg
    Member
    Posted 9 years ago #

    what file would be for the server config file you speak of? i'll take a look at that...

  16. burt
    Member
    Posted 9 years ago #

    cafeRg, your wp-blog-header.php file appears to be returning a blank line if I request that page specifically. I can see this by communicating with the server using HTTP over a telnet session.
    If you haven't tried replacing the wp-blog-header.php file that is on your server with the one from the download, you might want to.

  17. bscribe
    Member
    Posted 9 years ago #

    Please forgive and ignore if this is just so much more extra gluck. Narrative or ancedotal info is all I have at this pt to offer but maybe it turn out useful -- something in it strike a note, spark an idea, jostle a memory, help get a connection made? Lead to something specific. Again, if not, ignore please (read please do not mock, flame, what have you. Thanks in advance.)
    Troubles may be with things connected with firefox, extensions, java, profiles. Should add, ie and ms/windows on the whole. over the past several months I have had troubles surrounding what build of firefox and wordpress attempting to use at any given pt. Where it may work out cleaner and easier for you is where it is murkier and overwhelming, disheartening for me -- assuming you are the only one using your system is what I'm talking about. Whereas, for me, without warning, unexpectedly, I've had episodes of being called away from mine, to return to trying to pick up where I left off with the burden then of trying to remember, retrace steps, and so on, all convulated by, (read screwed) subject to finding out later that someone else - a kid I mentor who doesn't have his own computer but I let come to my place and use as he needs -- "made adjustments" -- taking a breath. Okay, so if you can do everything you need to do to get your firefox profile completely out of the picture and do clean reinstall, no extensions, no profile stuff, no java stuff carrying over, just basic clean download with known stable version, and get the same with your wordpress, you might get whatever is having its way with its own agenda out of the mix. Don't know about whatever hotfixes and added crap (if you run ms, that is) you've had to take on from all the ms so-called fixes for so-called security's sake. This last, I add, I suspect as having convaluted things concerning java runtimes associated where and with user profiles over time, that whole foggy mess, as this is where my mentoree in trying to help may have unknowingly got some of those hiddens moving in another direction. How I hope something will arise out of this thread to bring these "external entities" into the light and get stuff working together and not at odds.

  18. DJ Rg
    Member
    Posted 9 years ago #

    ok replaced the header file still nothing ..and bscribe fasinating reply ..if i follow ya.. i was thinkin mayb it was firefox but i dont think so..as i can get the rss file to run properly on IE ..one of the feeds i want is FeedBurner ..and in firefox it would say invalid XML file ..knowing RSS works in IE ..the thought struck me to try FeedBurner in IE..to no avail ..again invalid XML file...
    i even tried the atom.php file ..same thing..
    now let me show my ignorance here (as if i havent already) ..in my other blogs, they use an ATOM.XML file ...hmm xml file? do i have a xml file for WordPress? here's my ignorance... where is my XML file for WordPress?

  19. burt
    Member
    Posted 9 years ago #

    To rule out WP as the cause of this problem, can you create test.php in your blog directory with just this in it:
    <?php echo "test" ?>
    I'm wondering whether this might be a PHP issue. When that file is there, I'll have another look to see if the blank line is inserted between the chunk size and the word "test". You will only see the word "test" in your browser.

  20. bscribe
    Member
    Posted 9 years ago #

    Actually, it's the fact that you can do what you're doing in ie that led me to post. Assuming you want to run firefox, again, you might want to try a clean reinstall. However, KEY is meticulous separation of all profile, extension, java, runtimes, etc code from new clean reinstall. else it finds its way back in.

  21. DJ Rg
    Member
    Posted 9 years ago #

    ok..test.php is in blog directory

  22. DJ Rg
    Member
    Posted 9 years ago #

    i just have the bare bones firefox ..but i will do the clean install with 0.1.0 ..that should be out anyday.. maybe today ..when it comes to browsers ..i travel light even with IE, is strip down (as much as it can be)

  23. burt
    Member
    Posted 9 years ago #

    http://www.splashhall.org/blog/test.php returns a 404, page not found error.. where did you put it??

  24. DJ Rg
    Member
    Posted 9 years ago #

    in the same place as the index.php is .../blog/ folder/directory..
    was i suppose add something more than just..
    <?php echo "test" ?>

  25. burt
    Member
    Posted 9 years ago #

    Nope, that's all, but the server is returning an error that indicates that the file is not there. Can you reach:
    http://www.splashhall.org/blog/test.php
    and see the word "test" in your browser? When you can reach it without receiving a "page not found" error, then I should be able to check it as well.

  26. DJ Rg
    Member
    Posted 9 years ago #

    its there now

  27. Matt Mullenweg
    Troublemaker
    Posted 9 years ago #

    As I said in the one of the three other threads you've started on this, the problem is not in any code that came with WordPress, otherwise thousands of people would be reporting this.
    When you load a file like wp-rss2.php it includes lots of other files, and if there is a blank line on one of those it will cause this very problem you're seeing.
    So stop what you're doing, stop messing with all the WP files. Reupload any ones you may have changed. Please.
    Now delete any plugins you may have.
    Now finally open up wp-config.php and make sure there aren't any blank lines at the beginning or end.

  28. DJ Rg
    Member
    Posted 9 years ago #

    we must have ..ESP... i just did that ..put all backups back ..ok checking config now....

  29. DJ Rg
    Member
    Posted 9 years ago #

    well that got rid of that error and my blog ..heh...
    now i get this error...
    Fatal error: Call to undefined function: mysql2date() in /www/s/splashhall/htdocs/blog/wp-blog-header.php on line 84

  30. burt
    Member
    Posted 9 years ago #

    Check that all files are in the right place and are of the right size (i.e. they match the file sizes in the downloaded bundle). That particular function, mysql2date() is in the wp-includes/functions.php file.
    As a matter of interest, how are you putting these files on your server? Are you using an FTP client, or something else, like Frontpage, to publish them?

Topic Closed

This topic has been closed to new replies.

About this Topic