ajax sends by:
$.ajax({
type: 'POST',
url: '/Server/Cookies',
headers:
{
"RequestVerificationToken": '@GetAntiXsrfRequestToken()'
},
data: {
type: "set",
name: "cookieDialogShown",
value: "true",
path: "/",
@{
var expires = DateTime.Now.AddDays(30);
}
expires: "@expires"
},
success: function (data) {
console.log("Success. Cookie prompt will not be shown for 30 days.");
}
});