Redirecting to home url when click on Read


#1

http://readbookss.tk/test/
This the link of the book, when click on “read” or the content of the book it redirects to the home url.

What might have gone wrong


#2

Looks like you haven’t set up .htaccess properly. See here.


#3

Hello @ned Thanks for the reply…I have checked .htaccess file and looks like everything is okay…Follow is the .htacess file content…could you advise what might have gone wrong

BEGIN WordPress

RewriteEngine On RewriteBase / RewriteRule ^index\.php$ - [L]

add a trailing slash to /wp-admin

RewriteRule ^([_0-9a-zA-Z-]+/)?wp-admin$ $1wp-admin/ [R=301,L]

RewriteCond %{REQUEST_FILENAME} -f [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^ - [L]
RewriteRule ^([_0-9a-zA-Z-]+/)?(wp-(content|admin|includes).) $2 [L]
RewriteRule ^([_0-9a-zA-Z-]+/)?(.
.php)$ $2 [L]
RewriteRule . index.php [L]


ExpiresActive On
ExpiresByType image/jpg “access plus 5 minutes”
ExpiresByType image/jpeg “access plus 5 minutes”
ExpiresByType image/gif “access plus 5 minutes”
ExpiresByType image/png “access plus 5 minutes”
ExpiresByType text/css “access plus 5 minutes”
ExpiresByType application/pdf “access plus 10 minutes”
ExpiresByType text/javascript “access plus 5 minutes”
ExpiresByType image/x-icon “access plus 30 minutes”
ExpiresDefault “access plus 3 minutes”


RewriteEngine On
RewriteBase /
RewriteRule ^index.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]

END WordPress


#4

Your server is openresty (Console -> Network -> Headers -> Response Headers -> Server: openresty)

With Nginx there is no directory-level configuration file like Apache’s .htaccess or IIS’s web.config files. All configuration has to be done at the server level by an administrator, and WordPress cannot modify the configuration, like it can with Apache or IIS.

More info:
https://codex.wordpress.org/Nginx


#5

Thank you and will check this out