【发布时间】:2013-12-09 08:40:30
【问题描述】:
PHP 新手,并在 WordPress 网站的第 1 行之后更改了一些代码。 使用 Dreamweaver CC 上传。获取:
解析错误:语法错误,意外的 T_IF 在 /home/jodyrein/public_html/www.writersblogfinder.com/wp-content/themes/rockthebook/functions.php 第 1 行
在 www.writersblogfinder.com
这是前几行代码:
<?php
/**
* rockthebook functions and definitions
*
* @package rockthebook
*/
/**
* Set the content width based on the theme's design and stylesheet.
*/
if ( ! isset( $content_width ) )
$content_width = 640; /* pixels */
【问题讨论】:
-
尝试在 php 标记后按 Enter。
-
谢谢,但没用。
-
删除所有cmets。
-
现在我注意到当我下载文件时所有代码都在一行中://* * 根据主题的设计和样式表设置内容宽度。 /if ( !isset( $content_width ) ) $content_width = 640; / 像素 /if ( !function_exists( 'rockthebook_setup' ) ) :/* * 设置主题默认值并注册对各种 WordPress 功能的支持。