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

是否可以在.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)
    %>
    
    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?