English 中文(简体)
“<%”和“<%=”在嵌入的VB 文本中有何区别?
原标题:What s the difference between "<%" and "<%=" in embedded VBScript?

我正在使用一种以超文本为正文的正文法。 我注意到围绕上述法典线的以下两个不同方面:

<%= MyFunc(val1) %>

以及

<% MyFunc(val1) %>

这些章节开头使用“=”性质有什么区别?

最佳回答

<代码><%评价了服务器代码中的表述,但确实是tmit输出。

<代码><%= 并评价这一表述,但总结反应结果。 书写,从而产生产出。

问题回答

阁下:

<%= MyFunc(%)>

这确实意味着:

<%
Response.Write( MyFunc() )
%>

它对答复的启发性产出是很短的。

<%
MyFunc()
%>

以上只是该守则的操作,但只有<代码>Response,才获得回复的文字。 书面在职能/附属机构内部。





相关问题
CSS working only in Firefox

I am trying to create a search text-field like on the Apple website. The HTML looks like this: <div class="frm-search"> <div> <input class="btn" type="image" src="http://www....

image changed but appears the same in browser

I m writing a php script to crop an image. The script overwrites the old image with the new one, but when I reload the page (which is supposed to pickup the new image) I still see the old one. ...

Firefox background image horizontal centering oddity

I am building some basic HTML code for a CMS. One of the page-related options in the CMS is "background image" and "stretch page width / height to background image width / height." so that with large ...

Separator line in ASP.NET

I d like to add a simple separator line in an aspx web form. Does anyone know how? It sounds easy enough, but still I can t manage to find how to do it.. 10x!

热门标签