Is there a way to use “” in an external javascript file?
If you really want to do this you can do following <%@ Page ContentType=”text/javascript” Language=”C#” AutoEventWireup=”false” %> <%@ OutputCache Duration=”86400″ Location=”Any” VaryByParam=”None” %> var time = “<%= DateTime.Now.ToString() %>”; alert(time); And then reference it in your page <script src=”https://stackoverflow.com/questions/6542079/Scripts/file.aspx” type=”text/javascript”></script> Note When using mentioned method, the only way to pass target page controls client-ids, is … Read more