TEL:400-8793-956
当前位置:程序、服务器

PHP调试

提问者: 近期获赞: 浏览人数: 发布时间:2021-01-23 13:06:04

 问:我对这个php代码的问题视而不见。

 
有人可以睁开我的眼睛吗?
 
我得到:  解析错误:语法错误,意外的T_VARIABLE在线7。
 
<?php
 
$ todayis = date(“ l,F j,Y,g​​:i a”);
$ subject =“测验结果;
$ from = $ emailaddress;
 
$ message =” $ todayis \ n
名字:$ firstname \ n
姓氏:$ lastname \ n
测验分数:$ score \ n
电子邮件:$ from \ n
 
mail (“ someone@xxx.com ”,$ subject,$ message);
 
回显“ <h3>您的测验结果的副本已发送给安全员。</ h3>”;
?>
 
答:搞定了!
 
<?php
 
$ message =“ $ todayis \ n
名字:$ firstname \ n
姓氏:$ lastname \ n
测验分数:$ score \ n
”;
$ subject =“测验结果”;
$ from = $ emailaddress;
$ sendto =“ somethinghere@xxx.com ”;
 
mail(“ $ sendto”,$ subject,$ message,$ from);
 
回声“ <h3>您的测验结果的副本已发送给安全员。</ h3>”;
?>
上一篇: 所有访客的WordPress登录
下一篇: 奇怪的“意外的t_variable”错误