When Publishing A Website Default Document Name Keeps Getting Removed From IIS
Nov 7, 2010
I have an ASP.NET web site project, which I'm publishing to IIS on my Win2k8 R2 server. It has a default page called login.aspx. I set that up on the published web site.
Trouble is, every time I publish a new version of the web site, the login.aspx entry gets erased from the "Default Document" settings of the web site in IIS. This is very annoying. How can I publish my web site from Visual Studio without wiping out the default page every time?
View 1 Replies
Similar Messages:
Jan 19, 2011
I am trying to secure very mixed content that is located in an ASP.NET directory. For purposes of this question, it can be ~/MyApp/.
I want all of the content in the directory and its subdirectories restricted to authenticated users. The default.aspx page, though, should be accessible to everyone. This is the web.config in that directory:
[Code]....
Now if you are an unauthenticated user, everything works fine if you request [code]....
The problem occurs in that visitors do not always request "Default.aspx". We have a default document configured so that they get Default.aspx even if they just request "/MyApp". An authenticated user works fine, but an unauthenticated user is directed to the login page.
Now I know that essentially this happens because even though the request for "/MyApp/" will actually end up serving up "/MyApp/Default.aspx", the security system is only checking for "/MyApp/" since that is what I requested. That is then getting the default security for the directory.
How can you configure an exception to allow access when no particular file is requested in the directory??
Is there some dependency between DefaultDocumentModule and UrlAuthorizationModule? In this environment, the UrlAuthorizationModule has been removed and re-added in order to make sure it fires for non-managed requests. I would not expect that to change the order of execution, though, since UrlAuthorizationModule usually goes after DefaultDocument.
A workaround could be to set up the opposite security with the directory being open, and then trying to secure individual files. Because of the (changing) number of files, and extensions, etc, and the fact that you cannot use wildcards in a <location>, this is not really a workable solution for me.
View 1 Replies
Sep 12, 2010
I have defined this in the web.config of a subdirectory
<namespaces>
<remove namespace="App"/>
<add namespace="Tom"/>
</namespaces>
App is imported in the parent web.config file, Tom and App have classes with the same names.To avoid errors resulting from ambiguous class names I removed the App namespace from the sub-directory where the Tom namespace is used.
However the namespace App is still imported on content pages that have a master page outside the Tom directory. This causes the aforementioned errors.Here is my dir structure
-Root Directory
--Default.master
--web.config (App is added in web.config)
--Tom Sub-diretory
---web.config (App is removed in web.config)
---Content page that uses Default.master (Here is the problem)
---Page without master (Works OK)
View 2 Replies
Feb 11, 2011
'm trying to host a new web site on a company called M6.Net and I can't find the setting for default document. Anybody use this company?
View 8 Replies
Dec 19, 2010
How can i set different default document for each folder in my asp.net project.I have set a default document from IIS, but that doesn't show up for every folder browsed.I have already added HTMLs to the collection but they are not showing up, instead stander ed Forbidden error page shows up.
View 2 Replies
Dec 2, 2010
if i have a separate dll for each page on my server and that is working fine. if I make some changes in code behind file of a particular page say, xyz.aspx page. then I have to upload the dll of that particular page. and that refreshes the whole web application and all sessions and other values got disturbed in the application. Is there any way that uploading the xyz.dll (of page xyz.apsx) on refreshes the xyz.aspx and didn't disturb the whole web application.
View 1 Replies
Mar 31, 2010
I've got an Asp.net site set up on GoDaddy which is using UrlRewriter.net (not to be confused with UrlRewriting.net) to enable url rewriting which seems to be working ok, though I had to set IIS to run in IIS6 mode, rather than IIS7. The problem I have is that my default document is 'virtual' so while it's possible to browse to mydomain.com/default.aspx just going to mydomain.com/ doesn't work - I presume this is because IIS is expecting default.aspx to actually exist within the root directory of the website. Is there any way around this problem?EditAs requested, here is the rewrite rule from my web.config file.
<rewriter>
<rewrite url="^(/.+(.gif|.png|.jpg|.ico|.pdf|.css|.js)(?.+)?)$" to="$1" processing="stop" />
<unless url="~/Login.aspx|~/Page-Not-Found.aspx|~/ShowPage.aspx">
<rewrite url="^~/(.+).aspx" to="/ShowPage.aspx?PageName=$1" />
</unless>
</rewriter>
View 1 Replies
Feb 4, 2010
IIS6, ASP.NET 2.0, No Forms Authentication I'm calling Response.Redirect("~/foo.aspx"), but the default document ("Default.aspx") for my site is appearing. To make matters worse, it only happens intermittently. Sometimes the redirect displays the right page.
I've checked session state, and I don't see any values in the web.config (that is, I'm assuming I'm using the 20-minute defaults).
There's foo.aspx and foo2.aspx (and the default document, Default.aspx). All pages extend from BasePage, which extends Page.
BasePage has a property named ReturnPage:
protected string ReturnPage {
get {
if (Session["ReturnPage"] == null) {
Session["ReturnPage"] = "";
}
return Session["ReturnPage"].ToString();
}
set { Session["ReturnPage"] = value; }
}
Users click on a LinkButton on foo.aspx, and the click event handler ends with two lines of code:
ReturnPage = ResolveUrl("~/foo.aspx");
Response.Redirect(ResolveUrl("~/foo2.aspx"));
The Page_Load of foo2.aspx has problems, and its error handling calls Response.Redirect(ReturnPage).
When I view the response headers of foo2.aspx, the 302 location is string.Empty (that is, there isn't one). That same response header has the same ASP.NET Session ID as the response of foo.aspx.
And remember -- this is intermittent. Sometimes, you can click on that LinkButton and go effortlessly to foo2.aspx, no problem. You can process the click with the exact same data once, and it will fail. You'll navigate from the default document (Default.aspx, where you were sent by the "bug") back to foo.aspx, click again with the same data (the same row in the grid/table -- the same LinkButton, essentially), and you'll be redirected to foo2.aspx without issue.
View 4 Replies
Jan 30, 2010
Is there a way to programmatically know when someone is using the Default Document feature of IIS to access my page (that is, the name of my .ASPX isn't in their URL anywhere)?
View 2 Replies
Dec 5, 2010
This is what my website looks like:
When I build the website and upload everything as it is, I get this error:
Quote:
A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: SQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified) I guess I have to deploy Database, or?
View 10 Replies
Mar 11, 2010
I hv a query regarding publishing the website. I use aspnet2.0 and for uploading we use filezilla.
Whenever I make any changes to my website (either in aspx or aspx.cs page), I need to upload the entire website (along with my bin folder, after publishing)again otherwise my site just doesnt work.Its very time consuming.
View 6 Replies
Apr 1, 2011
I have created a website with asp.net and uses oracle connectivity with pl/sql developer.i have uses the crystal report which is a third party tool. how to purchase it.
i am using visual studio 2005 and yes i am using basic crystal crystal that comes with visual studio.
Now suppose i hav purchase a domain www.abc.com.
View 10 Replies
Nov 9, 2010
I am a bigineer in the asp.net with c#. May any one help me to know "What happen to all .cs files that contain the code on publishing."
View 6 Replies
Nov 29, 2010
I am trying to move my web application from my computer to a server by publishing as a web site. But, after publishing, the user controls defined in the designer files are no longer recognized by the code behind.
View 5 Replies
Nov 5, 2012
I've published my website and tried to host in my localsystem.Im getting the login page but cannot login to my application.When i click the submit button in the login page,the page simply refreshes and comesback.The page is not showing any error like 'invalid username or password' which i've set for not proper login
I am using visualstudio 2008 and iis 5.1.What could be cause of this error ??
View 1 Replies
Jan 1, 2014
How can i pulish my website online tell me the procedure ,steps?
View 1 Replies
Oct 27, 2010
My login.aspx is in a Login folder of my website. I want this to be the default document of my website in IIS. is this possible? or should I create a home.aspx page that redirects to login.aspx?
View 4 Replies
Jul 22, 2010
I basically have quite a large site collection with various site and sub sites that all contain their own document libraries. I need to change the default view of each document library to include the following fields:
Checked out to.
Check in comments.
This is ok as I have written an app that will loop through all existing lists and do this however is there a way I can change the template for a document library so that any future lists that are created will automatically contain these two fields in the their default view?
I am using WSS 3.0.
View 1 Replies
Sep 29, 2010
I have spent a day and a half trying to resolve this issue. Bascially have an ASP.net website with Forms Authentication on IIS7 using Framework 4.0.
The Authorization stuff seems to be working perfectly for every scenario with the exception of hitting it with no document specifed (Should resolve to Default Doc).
For example [URL] works perfectly, this page should allow anon access as specified in the web.config.
but if I hit [URL] Directly it redirects to the login page with Return URL set to "/" or Login.aspx?ReturnUrl=%2f
Some things I have tried:
1) Set Authentication to None and then the Default document worked so thats not the issue.
2) Added DefaultDocument attribute to Web.config
3) Deleted all entries for in Default Document list in IIS except for Default.aspx
4) Added MachineKey entry in Config
5) Toggled from Integrated to Classic pipeline in IIS
Here is what's in my config:
[code]...
View 6 Replies
Jun 4, 2010
I have two strange problems when I use routing in a web form application. Environment: IIS 7.5; .NET 4.0 and Windows 7 64 bit.
default document does not work if I use (http://www.)mydomain.com. The exception message is "The controller for path '/' was not found or does not implement IController". However, if I debug in VS 2010 (http://localhost:8080), this problem has never come out. Here mydomain.com and http://localhost:8080 hit the same code in the same folder of the same computer. I trapped the value of request.path. When local host is used, the value is "default.aspx" while "/" if mydomain.com is accessed. I can use one line (if "/" then redirect to default.aspx) to "fix" the problem but I believe it should have a better way. when I detect request.path, I got such a VERY strange request which I have never seen before: 192.168.1.11/StableWSDiscoveryEndpoint/schemas-xmlsoap-org_ws_2005_04_discovery! I have no idea where it is from. I do not use any web service in my code. The request is posted to the server, and the user agent is WSDAPI. I tried to debug the code from a different browsers other than IE. It looks like I do not get such a request. Edit: I just found the 192.168.1.11/StableWSDiscoveryEndpoint/schemas-xmlsoap-org_ws_2005_04_discovery request is sent from the domain control.
View 1 Replies
Jan 18, 2010
I have an ASP.NET website application, and there is a home page for my web site. I need to be able to change the default document of my website programmatically (C#) so that I can make another web page take priority above the one that already exists. I would then like to revert back to the previous default document order.
Example :
I have two home pages - Home1.aspx and Home2.aspx. In the IIS default document settings I have added the two pages and made Home1.aspx be the first default document then Home2.aspx the second. I need in some cases to be able to change the order of the two default documents so that Home2.aspx is the first default document then Home1.aspx the second.
How can I do that from my C# code?
View 3 Replies
Feb 1, 2011
I have one asp application. When i deploy this application in iis like www.xxxx.com , my index page is in the sub folder like root/home/index.asp , so when i set this as default document , browser will redirect to this url. But without redirection is this possible to load the default document in www.xxxx.com
I need my default document while browsing www.xxxx.com without redirecting to www.xxxx.com/home/index.asp
What shoud i do to achieve this?
View 5 Replies
Aug 16, 2010
Login not working after publishing asp.net website
I am used default login control, form based authentication and default sqlmembership provider.but in local my site working fine,when i publish it locally in iis means,the login is not working , i don't know what is the reason?
View 3 Replies
Aug 31, 2010
I have a ASP.NET Web application which has 2 projects(one for UI and one for Business layer)Now when i publish this for deployment,its giving me so many DLLS in bin folder which starts with prefix "App_Web...."in the name.How can i make it into only one DLL or 2 DLLS (one for UI and one for BL) ? I work with Visual studio 2010
View 1 Replies
Mar 9, 2011
Is there anyway I can put my custom name while publishing asp.net 2.0 website?
View 1 Replies