Hi @brentsoftware
The C1PageRoute.RegistrePathInfoUsage() functionality isn't supported for the root "/" page.
The easiest way to make a feature, would be to write and register in web.config an HTTP module, that would check check if the request is coming to username link, and does a URL rewrite to a link, where the name is passed with query string. Or you can save the user name in HttpContext.Items instead, and rewrite to "/"
Something like this:
public class UserNameRewriteModule: IHttpModule
The C1PageRoute.RegistrePathInfoUsage() functionality isn't supported for the root "/" page.
The easiest way to make a feature, would be to write and register in web.config an HTTP module, that would check check if the request is coming to username link, and does a URL rewrite to a link, where the name is passed with query string. Or you can save the user name in HttpContext.Items instead, and rewrite to "/"
Something like this:
public class UserNameRewriteModule: IHttpModule
{
public void Init(HttpApplication context)
{
context.BeginRequest += OnBeginRequest;
}
private void OnBeginRequest(object sender, EventArgs args)
{
var context = ((HttpApplication) sender).Context;
string rawUrl = context.Request.RawUrl;
// insert some proper check here
if (rawUrl != "/username")
{
return;
}
context.RewritePath("/?user=username");
}
public void Dispose()
{
}
}