mirror of
https://git.teknik.io/Teknikode/Teknik.git
synced 2023-08-02 14:16:22 +02:00
Fixed editing of podcasts
This commit is contained in:
parent
ffbdec715c
commit
fed8289852
@ -116,7 +116,7 @@
|
||||
episode = $("#edit_podcast_episode").val();
|
||||
title = $("#edit_podcast_title").val();
|
||||
description = $("#edit_podcast_description").val();
|
||||
allFiles = $("#edit_podcast_cur_files").val();
|
||||
allFiles = $("#edit_podcast_cur_file_list").val();
|
||||
|
||||
fd.append("podcastId", podcastId);
|
||||
fd.append("episode", episode);
|
||||
|
@ -146,9 +146,13 @@ namespace Teknik.Areas.Profile.Controllers
|
||||
{
|
||||
authcookie.Domain = string.Format("dev.{0}", Request.Url.Host.GetDomain());
|
||||
}
|
||||
#if DEBUG
|
||||
authcookie.Domain = Request.Url.Host.GetDomain();
|
||||
#endif
|
||||
// Make it work for localhost
|
||||
if (Request.IsLocal)
|
||||
{
|
||||
authcookie.Domain = Request.Url.Host.GetDomain();
|
||||
authcookie.HttpOnly = false;
|
||||
authcookie.Secure = false;
|
||||
}
|
||||
Response.Cookies.Add(authcookie);
|
||||
|
||||
if (string.IsNullOrEmpty(model.ReturnUrl))
|
||||
|
@ -58,8 +58,14 @@ namespace Teknik
|
||||
|
||||
// Allow this domain
|
||||
string origin = context.Request.Headers.Get("Origin");
|
||||
if (!string.IsNullOrEmpty(origin))
|
||||
if (!string.IsNullOrEmpty(origin) && !Request.IsLocal)
|
||||
{
|
||||
context.Response.AppendHeader("Access-Control-Allow-Origin", origin);
|
||||
}
|
||||
else if (Request.IsLocal)
|
||||
{
|
||||
context.Response.AppendHeader("Access-Control-Allow-Origin", "*");
|
||||
}
|
||||
}
|
||||
|
||||
protected void Application_PostAuthenticateRequest(Object sender, EventArgs e)
|
||||
|
Loading…
Reference in New Issue
Block a user