• "The return URL specified for request redirection is invalid" error when using forms authentication

     

    In SharePoint Server 2007, when you try and login to a forms-based site the .RedirectFromLoginPage results in the following error:

    "The return URL specified for request redirection is invalid"

    Basically, this would happen when you navigate to a URL like http://server/_layouts/login.aspx?ReturnUrl=default.aspx%3f%3a 

    So, why does this happen ?

    This is a problem with the URL validation on the login.aspx page. The reason why this fails is because we have the ' : ' colon character (the escape character ‘ %3a ’ in the query string. The URL query string validator does not seem to like the colon character at all.

    The colon is a reserved character, per the URI RFC. You CANNOT put an unencoded ' : ' in the query or hash of a URI, period.

    One workaround would be the need to %-encode the colon.

    Another one would be to use a code snippet. For more information on this, please see http://social.msdn.microsoft.com/Forums/en-US/sqlreportingservices/thread/cf27c390-07b1-4a48-b337-130a8e220069

  • SharePoint 2010 takes the first 3 property restrictions into account irrespective of the number of property restrictions specified in the search query

     

    Using the Enterprise Search keyword syntax in SharePoint Server 2010, you can build a search query that uses multiple property restrictions to narrow the search focus based on the specified condition. However, SharePoint will only take the first 3 property restrictions into account irrespective of the number of property restrictions specified in the search query.

    Currently, this is a known behavior. So, the next time when you build a search query, include 3 or less number of property restrictions using the search keyword syntax.

    References

    This does not state any kind of limitation on the number of property restrictions that can be present in a search query other than that the query cannot  exceed 2048 characters.