html嵌套的php的值传递到JS,该如何处理

WBOY
Release: 2016-06-13 13:34:26
Original
917 people have browsed it

html嵌套的php的值传递到JS
我的html里面嵌套一个php用来循环输出题目,php中有个变量值$time
要传递到JS里面进行倒计时?怎么实现传递?

------解决方案--------------------
function js(){
var time=
for ...
}
------解决方案--------------------
什么错误?那段代码要放入中。
------解决方案--------------------
exam.js ???
那你的 var t_time=; 能不报错吗?

将 exam.js 重名为 exam.php 才不会报错
------解决方案--------------------

探讨
exam.js ???
那你的 var t_time=; 能不报错吗?

将 exam.js 重名为 exam.php 才不会报错
Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!