0

Moved WordPress into a sub directory and got this error:

Fatal error: Function name must be a string in /home/content/61/11855861/html/wordpress/index.php on line 17

Here is my code:

<?php
/**
 * Front to the WordPress application. This file doesn't do anything, but loads
 * wp-blog-header.php which does and tells WordPress to load the theme.
 *
 * @package WordPress
 */

/**
 * Tells WordPress to load the WordPress theme and output it.
 *
 * @var bool
 */
define('WP_USE_THEMES', true);

/** Loads the WordPress Environment and Template */
require $wordpress ('/wordpress/wp-blog-header.php');
4

2 回答 2

3

您的错误在于这一行

require $wordpress ('/wordpress/wp-blog-header.php');

这不是 WordPress 的 index.php 脚本中的默认行。该$wordpress变量未定义,即使已定义,您也没有正确连接它。默认的是

require('./wp-blog-header.php');
于 2013-09-30T20:01:32.113 回答
0

你检查了这个链接:

给 WordPress 自己的目录

还:

移动 WordPress

额外说明:如果您对永久链接有疑问,您应该将永久链接设置返回到default,然后再将其返回给您自己的选择

于 2013-10-01T09:32:30.730 回答