wordpress .htaccess with permalinks

不羁岁月 提交于 2019-12-13 04:37:47

问题


I have a permalink working but as soon as I create a post it tells me that soory post not found permalink setting is to "/%pagename%/" and here is .htaccess:

    # BEGIN WordPress
    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /ryan/
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . ryan/index.php [L]
    </IfModule>
# END WordPress

回答1:


Try clearing the permalink setting in wp_options in the database and then reset permalinks in Wordpress. It's usually option_id 30 and called permalink_structure.




回答2:


Check your apache configuration and verify that for the directory in which you store your Wordpress installation you have following settings enabled (probably you will have more configuration options for the specific directory, but these are the minimum required for Wordpress fancy permalinks):

<Directory var/www/>
FollowSymLinks
AllowOverride All
</Directory>



回答3:


Do you have mod_rewrite installed on the server?




回答4:


Try %postname% in permalink setting rather than /%pagename%/



来源:https://stackoverflow.com/questions/2157279/wordpress-htaccess-with-permalinks

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!