I cannot get Javascript to run after ASP.NET postback from the client script block entered from the main page
Below is my main page logic, and it gets into postback, I confirmed with a breakpoint.
namespace MyAwesomeProjectThatWillTakeOverTheWorldIfNotForThisIssue { public partial class CommonContent : MasterPage { protected void Page_Load(object sender, EventArgs e) { Page.ClientScript.RegisterClientScriptBlock(GetType(), "script", "alert('Success!');", true); } } }
The problem is that the popup only appears on first boot, but not on postback.
What am I not doing right?
source share