码迷,mamicode.com
首页 > Web开发 > 详细

<% %> in html

时间:2018-02-12 18:41:42      阅读:193      评论:0      收藏:0      [点我收藏+]

标签:help   mat   state   cot   links   odi   href   rally   stat   

$(document).on(‘click‘, ‘.invoiceNumber‘, function () {
var string = <%= StaticHelper.GetCurrentCompanyId.ToString()%>;
string = string +"---"+ $(this).text();
alert(string);
});

 

https://forums.asp.net/t/1139381.aspx?what+are+these+special+tags+and+

hose tags can be hard to search for since the are generally discarded by search engines as noise...

here are some helpful links for you on the various tags.

<% %>  An embedded code block is server code that executes during the page‘s render phase. The code in the block can execute programming statements and call functions in the current page class. http://msdn.microsoft.com/en-gb/library/ms178135(vs.80).aspx

<%= %> most useful for displaying single pieces of information. http://msdn.microsoft.com/en-us/library/6dwsdcf5(VS.71).aspx

<%# %> Data Binding Expression Syntax. http://msdn.microsoft.com/en-us/library/bda9bbfx.aspx

<%$ %> ASP.NET Expression. http://msdn.microsoft.com/en-us/library/d5bd1tad.aspx

<%@ %> Directive Syntax. http://msdn.microsoft.com/en-us/library/xz702w3e(VS.80).aspx

<%-- --%> Server-Side Comments. http://msdn.microsoft.com/en-US/library/4acf8afk.aspx

<%: %> Like <%= %> But HtmlEncodes the output (new with Asp.Net 4). http://weblogs.asp.net/scottgu/archive/2010/04/06/new-lt-gt-syntax-for-html-encoding-output-in-asp-net-4-and-asp-net-mvc-2.aspx

<% %> in html

标签:help   mat   state   cot   links   odi   href   rally   stat   

原文地址:https://www.cnblogs.com/chucklu/p/8445033.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!