MVC- How to get parameter value from get request which has parameter names including dot characters
Use the following code:
public ActionResult method()
{
string param1 = this.Request.QueryString["param.1"];
string param2 = this.Request.QueryString["param.2"];
...
}
This will probably be your best bet:
/// <summary>
/// <paramref name="param.1"/>
/// </summary>
public void Test1()
{
var value = HttpContext.Request.Params.Get("param.1");
}
Get the parameter from HttpContext.Request.Params
rather than putting it as an explicit parameter