我得到這個錯誤:錯誤解析錯誤:語法錯誤,意想不到的T_STRING,期待T_CONSTANT_ENCAPSED_STRING
"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"
和線路14只是一個簡單的use
命令
13-15行:
add_action('headway_setup_child_theme', array('HeadwaySchematic', 'init'), 1);
use mfbcaptheme\mobilebrowsertheme;
require_once 'mobilebrowsertheme.php';
這是在客戶端的網站上,它在我的測試網站上工作得很好....不知道是什麼會導致這個錯誤。
請重新打開此問題。這個問題的答案 - 將PHP 5.2升級到5.3在2013年與很多人相關,並且今天依然相關。所以它可能有助於未來的遊客。 – icc97