.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month
Gaurav Pal
Post New Web Links

returnUrl -Heeeeeeeelp

Posted By:      Posted Date: October 04, 2010    Points: 0   Category :ASP.Net

Help! anybody out there? please help!!! 

I have decided to learn programming and have started with MVC. I used the MVC music store to learn. All went well untill I uploaded onto a production server.

The user login is not working. When a I login with the correct credential the login page just reloads. With wrong credentials it gives the appropriate error message. The login however works on my local IIS 7 which is the same as the host. The only difference between the local system and the live one is just the connection strings.

Any help would be very much appreciated. I am a total newbie and I think I have bitten more than I can chew and it is choking me now. Arrgggg!



View Complete Post

More Related Resource Links

ReturnURL using Forms Authentication

Hello I'm having trouble with the ReturnUrl property using forms authentication.  If my URL is http://www.mycoolsite.com/login.aspx?ReturnUrl=%2fsearch.aspx, the ReturnURL value in the querystring is ignored and it always sends me to the defaultUrl value default.aspx.  login.aspx: FormsAuthentication.RedirectFromLoginPage(txtEmail.Text, chkRememberMe.Checked) web.config:   <system.web>        <authentication mode="Forms">            <forms loginUrl="login.aspx"               protection="All"               timeout="30"               name=".ASPXAUTH"               path="/"               requireSSL="false"               slidingExpiration="true"                defaultUrl="default.aspx"

Forms Authentication - Disable ReturnUrl


Anyone know if it is possible to disable the behavior that automatically appends the ReturnUrl for forms-based auth?

Retain querystring values in ReturnURL?


I've got a couple pages in my web app that are used by external applications.  They will link to the pages, and pass in various querystring values to allow my app to do the searching and return the results in the page.  The problem is, if the user is not yet logged into the web app, they are sent to the login page, and the ReturnURL is truncated to include only the first QueryString value.  I lose the rest of the values.  So far I haven't figured out a solution to this.  Here's a quick example:

The external application links the user to:


If the user is not logged in they are sent to the login page, and the current URL looks like this:


Anyone kow how to get around this? 

Thanks for your help!


ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend