简体   繁体   中英

Wordpress force trailing slash at the end of the main domain page URL

After wordpress installation, all the links to the root domain are without slash, even the canonical tag in the home page have like http://domain.com instead of http://domain.com/ .

Is there any option to force wordpress to use the domain name and links with trailing slash at the end instead of without?

I only need it for the main domain, the post url are with trailing slash.

There is an option in Wordpress SEO by Yoast plugin that allows for that. I think it's the first option under the Permalinks-tab of the plugin. Success!

在“设置”>“自定义结构中的永久链接”下,添加“ /%postname%/”

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM