Publishing My Website II
am 26.01.2008 00:29:58 von Jonathan Wood
Okay, so forget about precompiling for now. I'll just FTP the files to my
site as this seems it will be trouble enough.
So, I see my web.config file has grown to well over 100 lines since
upgrading to VS2008. Now I need a web.config file for my site. I took the
existing one and changed the connection strings. Of course, it doesn't work
now. The error that appears is pasted below my signature.
My question is, how are we supposed to be dealing with this? Is it just
assumed that we will know what each and every line means that VS put there
and we'll know which lines to change, remove, and keep. Or is there actually
some sort of other method that can be used so my project will actually work?
Thanks.
--
Jonathan Wood
SoftCircuits Programming
http://www.softcircuits.com
<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
Server Error in '/' Application.
------------------------------------------------------------ --------------------
Runtime Error
Description: An application error occurred on the server. The current custom
error settings for this application prevent the details of the application
error from being viewed remotely (for security reasons). It could, however,
be viewed by browsers running on the local server machine.
Details: To enable the details of this specific error message to be viewable
on remote machines, please create a tag within a "web.config"
configuration file located in the root directory of the current web
application. This tag should then have its "mode" attribute
set to "Off".
Notes: The current error page you are seeing can be replaced by a custom
error page by modifying the "defaultRedirect" attribute of the application's
configuration tag to point to a custom error page URL.
Re: Publishing My Website II
am 26.01.2008 00:41:39 von Jonathan Wood
Actually, by working through a few things, the thing actually started
working, which is cool.
But I'm still curious as to what all those config settings are for and if I
should be deleting some of them.
Thanks.
--
Jonathan Wood
SoftCircuits Programming
http://www.softcircuits.com
"Jonathan Wood" wrote in message
news:Ok5L2o6XIHA.3696@TK2MSFTNGP03.phx.gbl...
> Okay, so forget about precompiling for now. I'll just FTP the files to my
> site as this seems it will be trouble enough.
>
> So, I see my web.config file has grown to well over 100 lines since
> upgrading to VS2008. Now I need a web.config file for my site. I took the
> existing one and changed the connection strings. Of course, it doesn't
> work now. The error that appears is pasted below my signature.
>
> My question is, how are we supposed to be dealing with this? Is it just
> assumed that we will know what each and every line means that VS put there
> and we'll know which lines to change, remove, and keep. Or is there
> actually some sort of other method that can be used so my project will
> actually work?
>
> Thanks.
>
> --
> Jonathan Wood
> SoftCircuits Programming
> http://www.softcircuits.com
>
> <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
>
> Server Error in '/' Application.
> ------------------------------------------------------------ --------------------
>
> Runtime Error
> Description: An application error occurred on the server. The current
> custom error settings for this application prevent the details of the
> application error from being viewed remotely (for security reasons). It
> could, however, be viewed by browsers running on the local server machine.
>
> Details: To enable the details of this specific error message to be
> viewable on remote machines, please create a tag within a
> "web.config" configuration file located in the root directory of the
> current web application. This tag should then have its
> "mode" attribute set to "Off".
>
>
>
>
>
>
>
>
>
>
>
> Notes: The current error page you are seeing can be replaced by a custom
> error page by modifying the "defaultRedirect" attribute of the
> application's configuration tag to point to a custom error
> page URL.
>
>
>
>
>
>
>
> defaultRedirect="mycustompage.htm"/>
>
>
>
>
Re: Publishing My Website II
am 29.01.2008 00:46:38 von Coskun
On Sat, 26 Jan 2008 01:41:39 +0200, Jonathan Wood
wrote:
> Actually, by working through a few things, the thing actually started
> working, which is cool.
Glad that it works.
Just to tell what that error was... The error that you see is a common
error avoiding your visitors to see the complete and detailed exception.
>
> But I'm still curious as to what all those config settings are for and
> if I should be deleting some of them.
To see the complete and detailed exception, you either have to log it
somewhere and then watch the log file/database/event logger or you have to
set "customErrors" attribute to "off" as described within the error that
you see.
Other than that, web.config file is a special file which means a lot for
ASP.NET. There are some other files like app.config (for Desktop
applications and class libraries) and machine.config which I will not
describe within the context of this post.
Using web.config, you can set most of the properties of your web
site/application. You can even create custom sections and set their
properties in web.config file. So, if VS adds something to that file, let
them stay there, though sometimes VS might add unnecessary configuration
and if you know what they really mean, you can remove them. For example,
if you will not use Microsoft Ajax in your web application, you will not
most probably need the configuration of Microsoft Ajax in your web.config
file.
If you still think that there is a lot of information in that file and you
just want to see your connection strings clearly, please refer to one of
my posts describing how to achieve that:
http://sunali.com/2008/01/23/configsource-property-dividing- configuration-files-into-pieces/
>
> Thanks.
>
All the best,
Coskun SUNALI
Microsoft MVP
http://sunali.com
http://propeople.dk