Victor Charles
asked on
Help with deploying application to a web server using FTP
Hello,
I tried to publish (FTP) my application using the VS 2010 tool, but but when I try to access the application, I receive the following error: Do I need to modify my config file before I publish my application?
Error:
Description: Application error on the server. The current custom error settings for this application prevent the details of the application error (for security) is not remotely be displayed. However, they can be viewed by browsers running on the local server.
Details: You can view the details of this error message on the local machine, by creating a <customErrors> tag in the web.config configuration file located in the root directory of the current web application. The mode attribute this <customErrors> tag should then be set to "Off".
<!-- Web.Config Configuration File -->
<configuration>
<system.web>
<customErrors mode="Off"/>
</system.web>
</configuration>
Notes: The current page can be replaced by a custom error page by the defaultRedirect attribute of the application of these tags <customErrors> configuration set so that it points to a custom error page URL.
<!-- Web.Config Configuration File -->
<configuration>
<system.web>
<customErrors mode="RemoteOnly" defaultRedirect="mycustomp age.htm"/>
</system.web>
</configuration>
I tried to publish (FTP) my application using the VS 2010 tool, but but when I try to access the application, I receive the following error: Do I need to modify my config file before I publish my application?
Error:
Description: Application error on the server. The current custom error settings for this application prevent the details of the application error (for security) is not remotely be displayed. However, they can be viewed by browsers running on the local server.
Details: You can view the details of this error message on the local machine, by creating a <customErrors> tag in the web.config configuration file located in the root directory of the current web application. The mode attribute this <customErrors> tag should then be set to "Off".
<!-- Web.Config Configuration File -->
<configuration>
<system.web>
<customErrors mode="Off"/>
</system.web>
</configuration>
Notes: The current page can be replaced by a custom error page by the defaultRedirect attribute of the application of these tags <customErrors> configuration set so that it points to a custom error page URL.
<!-- Web.Config Configuration File -->
<configuration>
<system.web>
<customErrors mode="RemoteOnly" defaultRedirect="mycustomp
</system.web>
</configuration>
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Thanks, I tried option 2 and still same error, just contacted the web server admi office, they are checking to see what is wrong.
just want to confirm, normally if the application runs on my local server it should work in another server without further modification when I deploy via FTP right? as mentioned my datasource is xml, no need to configure database servers.
just want to confirm, normally if the application runs on my local server it should work in another server without further modification when I deploy via FTP right? as mentioned my datasource is xml, no need to configure database servers.
Is strange... if you put the configuration of errors you should be able to see the server error from within any computer...
Regarding the ftp upload, keep in mind that there are several things that can affect your code execution. Maybe your site directories on the server have different permissions than your local machine, maybe you are using global urls on certain points and they change when you upload the site and try to access through the new url.
The fact is that you need to see what the error is to be able to wonder what is happening.
Regarding the ftp upload, keep in mind that there are several things that can affect your code execution. Maybe your site directories on the server have different permissions than your local machine, maybe you are using global urls on certain points and they change when you upload the site and try to access through the new url.
The fact is that you need to see what the error is to be able to wonder what is happening.
ASKER
OK, I will look further into it.
Thanks for your Help.
Victor
Thanks for your Help.
Victor
ASKER
Below is the information in my web.Debug.config and Web.Release,config. I am using XML as my datasource, no need for SQL server.
A. Web.Debug.config
<configuration xmlns:xdt="http://schemas.microsoft.com/XML-Document-Transform">
<!--
In the example below, the "SetAttributes" transform will change the value of
"connectionString" to use "ReleaseSQLServer" only when the "Match" locator
finds an atrribute "name" that has a value of "MyDB".
<connectionStrings>
<add name="MyDB"
connectionString="Data Source=ReleaseSQLServer;In
xdt:Transform="SetAttribut
</connectionStrings>
-->
<system.web>
<!--
In the example below, the "Replace" transform will replace the entire
<customErrors> section of your web.config file.
Note that because there is only one customErrors section under the
<system.web> node, there is no need to use the "xdt:Locator" attribute.
<customErrors defaultRedirect="GenericEr
mode="RemoteOnly" xdt:Transform="Replace">
<error statusCode="500" redirect="InternalError.ht
</customErrors>
-->
</system.web>
</configuration>
Web.Release.config
<?xml version="1.0"?>
<!-- For more information on using web.config transformation visit http://go.microsoft.com/fwlink/?LinkId=125889 -->
<configuration xmlns:xdt="http://schemas.microsoft.com/XML-Document-Transform">
<!--
In the example below, the "SetAttributes" transform will change the value of
"connectionString" to use "ReleaseSQLServer" only when the "Match" locator
finds an atrribute "name" that has a value of "MyDB".
<connectionStrings>
<add name="MyDB"
connectionString="Data Source=ReleaseSQLServer;In
xdt:Transform="SetAttribut
</connectionStrings>
-->
<system.web>
<compilation xdt:Transform="RemoveAttri
<!--
In the example below, the "Replace" transform will replace the entire
<customErrors> section of your web.config file.
Note that because there is only one customErrors section under the
<system.web> node, there is no need to use the "xdt:Locator" attribute.
<customErrors defaultRedirect="GenericEr
mode="RemoteOnly" xdt:Transform="Replace">
<error statusCode="500" redirect="InternalError.ht
</customErrors>
-->
</system.web>
</configuration>