如何将值JavaScript变量传递给PHP?
问题描述:
将值JavaScript变量传递给PHP。
Passing value JavaScript variable to PHP.
示例
JavaScript
Var ddd='aaaa'
PHP
if (ddd="aaaa"){do somehting...}
答
Javascript是客户端脚本仅在页面完全加载后执行的语言。另一方面,
PHP是一个按需编译脚本。它解析文件中的PHP并将生成的HTML输出到用户的浏览器。
Javascript is a Client side scripting language that is only executed after the page is fully loaded. PHP on the other hand is an on-demand compiling script. It parses the PHP within the file and outputs the resulting HTML to the user's Browser.