Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Hi, Actually WHAT exactly is the 1

Status
Not open for further replies.

Deadline

Programmer
Feb 28, 2001
367
US
Hi,

Actually WHAT exactly is/are the difference(s) between
Code:
<% %>
and

Code:
<SCRIPT LANGUAGE=&quot;VBSCript&quot; RUNAT=Server>
?

I am sure they are not equal.

Thank you in advance.

RR
:)

Keywords
RUNAT
Server
SCRIPT Tag
VBScript
<%
%>
difference
 
Actually, they are about the same.

<%%> is a shortcut, but with <% and %> you can do <%=varname%> which is a shortcut for <%response.write(varname)%>. Just placing =varname on a line within the <SCRIPT> tag does not work.

Another thing is that <% %> respects the default language you set up in IIS control panel. And that the ASP parser first evaluates all the <SCRIPT> tags and then the <%> tags (NOT SEQUENTIALLY) or the other way around.. I am not quite sure which one it is.

Maybe there's something else which I don't know of... Yours,

Rob.
 
You are right.

You know what ?

I actually had something like this inside <SCRIPT> tag.
Code:
Response.Write &quot;<FORM>blahblah</FORM> &quot;


It always wrote the above outside the closing </HTML> tag at the very bottom, when I viewed the source from the browser.

WHen I wrote the same thing within <%%> I discovered that they were written inside the <BODY></BODY> tag, the right place where I intended them to be.

This is the reason, I asked the question.

Thank you very much.


RR
:)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top