douge3830
2018-11-13 19:17
浏览 97
已采纳

是否可以在.asp文件中的VBScript块中运行php代码?

Is it possible to run some php code in a VBScript block in a .asp file?

Something like:

<%@ LANGUAGE="VBSCRIPT" %>
<%
Set str = <?php $s = "hello world"; echo $s; ?>
%>

Thanks

  • 写回答
  • 关注问题
  • 收藏
  • 邀请回答

1条回答 默认 最新

  • douhunkuang8955 2018-11-13 19:26
    已采纳

    That will not work.

    But classic ASP and VBScript is a combination that is similar to PHP.
    See classic ASP reference.

    The code in your question will look like

    <%@ LANGUAGE="VBSCRIPT" %>
    <%
    s = "hello world"
    Response.Write(s)
    %>
    
    已采纳该答案
    打赏 评论

相关推荐 更多相似问题