这里没关系。我的请求:
SELECT SQL_CALC_FOUND_ROWS wp_posts.ID FROM wp_posts WHERE 1=1 AND (((wp_posts.post_title LIKE \'%a%\') OR (wp_posts.post_content LIKE \'%a%\'))) AND (wp_posts.post_password = \'\') AND wp_posts.post_type IN (\'post\', \'page\', \'attachment\') AND (wp_posts.post_status = \'publish\') ORDER BY wp_posts.post_date DESC LIMIT 0, 10
我试着改变
a
查询查找标题或内容包含该字符串的帖子。
我从外部文件中尝试了它。我的文件内容:
define( \'WP_USE_THEMES\', false );
require(\'wordpress/wp-blog-header.php\');
$a = new WP_Query( \'s=a\' );
echo \'<pre>\';
print_r( $a );
echo \'</pre>\';