I get this error:
我收到此错误:
"Parse error: syntax error, unexpected T_STRING, expecting T_CONSTANT_ENCAPSED_STRING or '(' in [wordpress dir]/wp-content/themes/[my-theme]/functions.php on line 14"
“解析错误:语法错误,意外T_STRING,期待T_CONSTANT_ENCAPSED_STRING或'('[wordpress目录] / wp-content / themes / [my-theme] /functions.php在第14行”
And line 14 is just a simple use
command...
第14行只是一个简单的使用命令......
Line 13-15:
13-15行:
add_action('headway_setup_child_theme', array('HeadwaySchematic', 'init'), 1);
use mfbcaptheme\mobilebrowsertheme;
require_once 'mobilebrowsertheme.php';
This is on a client's site and it works just fine on my test site....Not sure what would cause this error.
这是在客户端的网站上,它在我的测试网站上工作正常....不确定会导致此错误的原因。
1 个解决方案
#1
36
Make sure they are running PHP 5.3 or later. If they are running an earlier version they won't have support for namespaces.
确保它们运行的是PHP 5.3或更高版本。如果它们运行的是早期版本,则它们不支持名称空间。
#1
36
Make sure they are running PHP 5.3 or later. If they are running an earlier version they won't have support for namespaces.
确保它们运行的是PHP 5.3或更高版本。如果它们运行的是早期版本,则它们不支持名称空间。