IIS 7 Web Site Issues

IIS 7 Web Site Issues

am 03.12.2007 22:33:02 von StevieT

I am using VS2005 and creating a simple web application (file based). Works
fine when running in the Dev environment.

Then I open IIS and create a new web site and application (points to a copy
of my file based web site). Now the site works pretty much but it does not
find any of the referenced gifs, css files etc. When I type the address of a
gif into the browser it does not error, just doesnt show anything. What
silly thing am I overlooking?

Code:
href="~/app_themes/AAF.css" runat="server" />

No style sheet applied by this!

TIA,
Steve

Re: IIS 7 Web Site Issues

am 04.12.2007 01:58:03 von Ken Schaefer

Are you sure that the ASPX is being processed?

If you look in the HTML source of the webpage you see in your browser, do
you see the literal code rather than the proper link?

Cheers
Ken

--
My IIS Blog: www.adOpenStatic.com/cs/blogs/ken

"StevieT" wrote in message
news:C4001DDC-4B2A-4885-B5A7-727B822839DB@microsoft.com...
>I am using VS2005 and creating a simple web application (file based).
>Works
> fine when running in the Dev environment.
>
> Then I open IIS and create a new web site and application (points to a
> copy
> of my file based web site). Now the site works pretty much but it does
> not
> find any of the referenced gifs, css files etc. When I type the address
> of a
> gif into the browser it does not error, just doesnt show anything. What
> silly thing am I overlooking?
>
> Code:
> > href="~/app_themes/AAF.css" runat="server" />
>
> No style sheet applied by this!
>
> TIA,
> Steve

Re: IIS 7 Web Site Issues

am 04.12.2007 08:10:34 von David Wang

On Dec 3, 1:33 pm, StevieT wrote:
> I am using VS2005 and creating a simple web application (file based). Works
> fine when running in the Dev environment.
>
> Then I open IIS and create a new web site and application (points to a copy
> of my file based web site). Now the site works pretty much but it does not
> find any of the referenced gifs, css files etc. When I type the address of a
> gif into the browser it does not error, just doesnt show anything. What
> silly thing am I overlooking?
>
> Code:
> > href="~/app_themes/AAF.css" runat="server" />
>
> No style sheet applied by this!
>
> TIA,
> Steve



Sounds like static files (like .css, .gif) are not configured to be
downloadable. This is a problem with your handler definition.
1. Make sure that "Static File" feature is installed. It should be by
default
2. Are you running the application in "Integrated Mode" or "Classic
ASP.Net Mode"
3. If Classic mode, then please provide the and
sections applicable to the URL in question. If in
Integrated mode, please provide the section applicable to
the URL in question

How to do #3 is to look up the appropriate sections in either the
web.config file in the directories or the appropriate tag
for the URL in the applicationHost.config file.

Recently, someone else also had problems with static files not being
shown, no errors, and it was due to improper definition that
came from some other software installation. It left a handler for
StaticFile that did not serve up downloads, thus no static files were
being handled. Search this newsgroup for that thread, also with me.

IIS7 is highly extensible and configurable, so with a single
misconfiguration any functionality can be crippled or misbehave. It
gives great power to those that want to leverage the server. It also
means it is very sensitive and easy to misconfigure and malfunction.


//David
http://w3-4u.blogspot.com
http://blogs.msdn.com/David.Wang
//

Re: IIS 7 Web Site Issues

am 04.12.2007 18:13:03 von Steve Taylor

Well, I appreciate that! Yes, it was that the "Static File" feature was not
on. So many new things in IIS 7!

"David Wang" wrote:

> On Dec 3, 1:33 pm, StevieT wrote:
> > I am using VS2005 and creating a simple web application (file based). Works
> > fine when running in the Dev environment.
> >
> > Then I open IIS and create a new web site and application (points to a copy
> > of my file based web site). Now the site works pretty much but it does not
> > find any of the referenced gifs, css files etc. When I type the address of a
> > gif into the browser it does not error, just doesnt show anything. What
> > silly thing am I overlooking?
> >
> > Code:
> > > > href="~/app_themes/AAF.css" runat="server" />
> >
> > No style sheet applied by this!
> >
> > TIA,
> > Steve
>
>
>
> Sounds like static files (like .css, .gif) are not configured to be
> downloadable. This is a problem with your handler definition.
> 1. Make sure that "Static File" feature is installed. It should be by
> default
> 2. Are you running the application in "Integrated Mode" or "Classic
> ASP.Net Mode"
> 3. If Classic mode, then please provide the and
> sections applicable to the URL in question. If in
> Integrated mode, please provide the section applicable to
> the URL in question
>
> How to do #3 is to look up the appropriate sections in either the
> web.config file in the directories or the appropriate tag
> for the URL in the applicationHost.config file.
>
> Recently, someone else also had problems with static files not being
> shown, no errors, and it was due to improper definition that
> came from some other software installation. It left a handler for
> StaticFile that did not serve up downloads, thus no static files were
> being handled. Search this newsgroup for that thread, also with me.
>
> IIS7 is highly extensible and configurable, so with a single
> misconfiguration any functionality can be crippled or misbehave. It
> gives great power to those that want to leverage the server. It also
> means it is very sensitive and easy to misconfigure and malfunction.
>
>
> //David
> http://w3-4u.blogspot.com
> http://blogs.msdn.com/David.Wang
> //
>