The XML page cannot be displayed

written by Andrew Tobin on Wednesday, May 24 2006

Howdy y'all,

Okay, well it's been a while since my last post and not with lack of anything to write about - instead I've just been too busy, and all round "tired".  Yes, in the physical sense, but also somewhat in the mental sense with all thats going on at work...

Yeah, I know my coworkers will find that funny because not so much is going on at work, but with my slight tendancy to stress things are not fun for the moment - but looking up! :)

Okay, now onto todays topic.

I've had the worst time getting Community Server to work on my local machine.  You'll have noticed that Mabster has skinned his site over, which is something I've been meaning to do for a long time (along with those 500 other projects I never get onto).

Well I decided to put Community Server onto my machine so I could play around and see what is indeed possible and I came up with an error message as follows:

The XML page cannot be displayed

Cannot view XML input using XSL style sheet. Please correct the error and then click the Refresh button, or try again later.


A name was started with an invalid character. Error processing resource 'http://localhost/cs/Default.aspx'. Line 1, ...

<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="_Default" %>  -^
Okay, well that gives you the gist of it, the code might not be exact as I set up another script to mirror the issue.
I found some similar input on the Community Server forums:
http://communityserver.org/forums/thread/531227.aspx

http://communityserver.org/files/40/betareleases/entry506323.aspx

http://communityserver.org/forums/thread/521265.aspx

http://communityserver.org/forums/thread/511415.aspx

As well as this I sent off an issue to Telligent (or the Community Server site) team and got no response on this issue, or on the one that means I cannot actually log in to their forums (from two accounts I've set up - it's probably user error in some way, but I won't know since they haven't answered me).

I've been searching around for the solution and found a lot of mixed up responses all of which end with the advice: run "%windir%\Microsoft.NET\Framework\v2.0.50727\aspnet_regiis.exe -i"

This did not work for me, time and time again.

What I found out in my case was, there may have been a conflict with either:

  1. I installed IIS after I installed the .NET Framework.
  2. I installed the Atlas beta - which apparently has issues.
  3. I have Zone Alarm.
  4. Theres something wrong out there in the air that causes bugs in computers.

As I couldn't quite narrow it down I had to do some searching. 

What I did come up with, was that although the .NET framework was installed, and IIS could see it on my local machine - .aspx files were not mapped to my IIS file mappings.

You can find your mappings under:

Control Panel -> Administrative Tools -> Internet Information Services

then:

  1. Right-Click on the Site you want.
  2. Choose Properties.
  3. Go to the "Directory" tab.
  4. Click the "Configuration" button.
  5. Go to the "Mappings" tab.
  6. Look in the "Application Mappings" list.

If you do not see ".aspx" listed as a mapping, your IIS to .NET Framework mappings are not correct.

In this case, try to run the command: "%windir%\Microsoft.NET\Framework\v2.0.50727\aspnet_regiis.exe -i"

(You can do this from a command prompt or from the Start -> Run menu).

If that does not correct your mappings you may have to do what I did, which is uninstall IIS.

This becomes a bit more difficult, but I can assume if you're trying to install CS then you're probably not terrible with the computer thingy, right?

Have your Windows XP discs on standby!

You can uninstall IIS from:

Control Panel -> Add or Remove Programs

  1. Choose the: Add/Remove Windows Components button.
  2. Click off Internet Information Services (IIS) checkbox.
  3. Hit "Next" and proceed to uninstall.

Then reinstall IIS from exactly the same place - Add/Remove Windows Components.

Then run the script: "%windir%\Microsoft.NET\Framework\v2.0.50727\aspnet_regiis.exe -i"

Make sure your ASP .NET site is back in the IIS web sites menu, and you may want to make sure its got the icon for a website and not just a web folder.

If it doesn't, just go to the sites properties (Right-Click) and on the "Directory" tab, check to see if the "Application Settings" are filled in.  If they aren't there will be a "Create" button.

Hit that "Create" button, and then check the "Configuration" button that the mappings are all in there.

Test your ASP .NET page and it should, hopefully come up.

If they aren't - well, theres something else thats wrong and give me a holler and I'll try to help out where I can.  I would answer this issue on the Community Server forums, but see the above issue of them not telling me why I cannot log in :)

Note 1: You're version of the .NET Framework version may vary, check the c:\Windows\Microsoft.NET\Framework directory if the aspnet_regiis script doesn't work as I've stated.

Note 2: This issue isn't just to do with Community Server, but all ASP .NET pages you'll serve up on your IIS server - I've just posted it this way because it was Community Server I was trying to install (read: It's not a CS problem, it's a .NET and IIS problem).

Similar Posts

  1. Publishing a Microsoft Access Application (mde) with Clickonce
  2. SQL Code Camp - Day 1
  3. Code Camp Oz 2008

Comments

  • BigO on on 6.02.2006 at 12:00 AM

    BigO avatar

    Crucible, Crucible, Crucible.... you should take a bow and not be so modest about "not much going on at work": you're feeling tired because you're working 'ken hard!!!  From all those who benefit from your skill and commitment to the task;  Thank you.
    (Just a minor point of clarification on the name; it is Big "O", NOT "Big Zero" (although Crucible may disagree).  Thanks you and avagoodweekend.)

  • Rochak Agrawal on on 6.06.2006 at 12:00 AM

    Rochak Agrawal avatar

    Mr. Crucible,

    It was through a magic stroke of google luck that I landed to your blog and I thank my stars for it. Your explanation was fool proof. Thanks a lot.

    Rochak

  • thumper on on 6.06.2006 at 12:00 AM

    thumper avatar

    Or is it Mrs Crucible?

  • crucible on on 6.06.2006 at 12:00 AM

    crucible avatar

    you know, after those three magical minutes we spent together I thought you would have known that its definately Mr, thank you Thumper.

    Although I'm still undecided about you.

    And Rochak its great! Helping just one person helps my karmic points - and I'm really depending on those!

    So it is great to get some feed back mate! :)

  • Carol on on 6.24.2006 at 12:00 AM

    Carol avatar

    Thanks for your very detail explanation.

  • novalis78 on on 6.24.2006 at 12:00 AM

    novalis78 avatar

    Exactly what i was looking for, thx a lot!

  • cj on on 7.01.2006 at 12:00 AM

    cj avatar

    Great work.
    This entry was the first returned in my google search and was clearly explained and work wonderfully. Fix in 5 minutes. I was thinking I will be googling for a couple of hours and reading through crap, how wrong was I. You did the hard work for me.
    Cheers
    CJ

  • Nasha on on 7.20.2006 at 12:00 AM

    Nasha  avatar

    I got this problem and tried many ways . None of them could help.

    After I read this message and followed to do what was told here, I got my problem resolved. It really great !

    Thanks very much !

  • crucible on on 7.21.2006 at 12:00 AM

    crucible avatar

    Thanks peeps for the kind words, it very encouraging to know it's helped a few people, and I may have to post more of this kind as I run across issues.

  • jxn on on 7.29.2006 at 12:00 AM

    jxn avatar

    thank you!

  • Bryant Likes on on 8.02.2006 at 12:00 AM

    Bryant Likes avatar

    Thanks for the tip! I had to reinstall IIS as you suggested and then everything worked!

  • Tigger on on 8.18.2006 at 12:00 AM

    Tigger avatar

    I had a similar prob. , did everything mentioned above, didn't help in my case. But adding following stap solved my prob.

    I have ASP 2.0 also installed inaddition to 1.x, threfore I went to IIS > Properties > ASP.NET (tab) > ASP.NET veriosn - 1.x (which I wanted to run.)

  • Dan from NJ on on 9.15.2006 at 12:00 AM

    Dan from NJ avatar

    I had the same exact problem with the same exact configuration and this helped me greatly. You're a saint!

    A couple of things that might help other people:

    Use the "Visual Studio 2005 Command Prompt" and all you'll have to type is aspnet_regiis -i.

    Go to Start > All Programs > Microsoft Visual Studio 2005 > Visual Studio Tools > Visual Studio 2005 Command Prompt

    When I was done, I registered ASP.NET 1.1 the same way and then registered Atlas and it all worked like a charm.

    Make sure you have all your sites configured to the proper version of asp.net:

    Right Click on "My Computer" and click "Manage" Find your web application and view the properties. Go to the asp.net tab and set the version as applicable.

    Now, I wonder if you can just simply add the appropriate mappings manually... :)

  • Suzie on on 12.21.2006 at 12:00 AM

    Suzie avatar

    Thanks a lot to both crucible and dan foe the wonderful tips. I am a newbee in .net and was just not being able to start off with my first hello world lessons :) you both are angels!!

  • Method_Paul on on 7.28.2009 at 1:41 PM

    Method_Paul avatar

    Thanks man. That pointed me in the right direction.

    By the way, for anyone else reading this, I had all the same problems, but didn't have to resort to reinstalling IIS.

    I recreated the web site under the websites node in IIS, and all the mapping showed up there. So I removed all virtual directories under the old website, assigned them to the new website, and then reinstalled CS under the new website. Viloa it all worked. After two days of struggling with Telligent forums and every post going to aspnet_regiis -i.......this was awesome to stumble across.

Post a comment

Options:

Size

Colors