FormsAuthentication
There are 2 entries for the tag
FormsAuthentication
Since administration was the next part I wanted to work on.
I decided that for the moment I just want a little login for in the upper corner like
I decided to put the login screen view logic into a user control, and added the following user control named Login.ascx and placed it into the Shared
<%@ Control Language="C#" Inherits="System.Web.Mvc.ViewUserControl" %>
<%if(!Page.User.Identity.IsAuthenticated) {%>
<form action="/Home/Login" method="post" id="LoginForm">
<span id="EmailLabel">Username:</span><br />
<%=Html.TextBox("Username")%><br />
<span id="PasswordLabel">Password:</span><br />
...
posted @ Friday, December 14, 2007 12:16 AM |
I figured out what was happening in my previous post. It makes a bit more sense now that I have seen it, being able to just stop working on something is handy, basically the Rss feeds don't do URL rewriting. So the call to /test1/Admin/ModeratedCommentRss.aspx uses the /web.config and would use the /test1/Admin/web.config, but it has no reason to look at the /Admin/web.config.
Not completely sure how I should change this. Right now I have the ModeratedCommentRss.aspx checking to see if the requestor is an Admin, and if not it calls FormsAuthentication.RedirectToLoginPage(). This works, but I would rather a solution that didn't...
posted @ Sunday, September 16, 2007 4:19 PM |