If your Z-BlogPHP site is installed in the secondary directory, you need to use pseudo static technology to optimize the site URL and improve the efficiency of search engine spiders. The following is an example of the pseudo static rules of nginx: # Subdirectory rules should be placed first; location /sub/ { if (-f $request_filename/index.html) { ...
If your Z-BlogPHP site is installed in the secondary directory, you need to use the pseudo static technology to optimize the site URL and improve the Search Engines Spider capture efficiency. The following is an example of the pseudo static rules of nginx:
#Subdirectory rules should be in front; location /sub/ { if (-f $request_filename/index. html ) { rewrite (.*) $1/index.html break; } if (-f $request_filename/index.php) { rewrite (.*) $1/index.php; } if (!-f $request_filename) { rewrite (.*) /sub/index.php; } } #Root directory rule location/{ if (-f $request_filename/index.html) { rewrite (.*) $1/index.html break; } if (-f $request_filename/index.php) { rewrite (.*) $1/index.php; } if (!-f $request_filename) { rewrite (.*) /index.php; } }
Statement: Some of the resources on this site are original works on the site, and some are publicly shared and collated based on the Internet. The copyright belongs to the original author.
If it infringes your rights, please contact our website, and we will deal with it as soon as possible. Thank you. Please indicate the source of the transfer
Link to this article: https://www.umtheme.com/zblog/224.html