Вопрос

Does anyone know how i would write the following in WebMatrix ASP.Net Web Pages?

return Content(Constants.Gateway.WebhookNotification.Verify(Request.QueryString["bt_challenge"]));

I think the return Content method is used by MVC only?

Это было полезно?

Решение

It depends on what you want to do with the result of the expression, but you can render it to the browser like this:

@Constants.Gateway.WebhookNotification.Verify(Request.QueryString["bt_challenge"]))

Or you can store it in a variable:

var myVar = Constants.Gateway.WebhookNotification.Verify(Request.QueryString["bt_challenge"]));
Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top