简体   繁体   中英

How to display sitemap on the 404 page in Drupal 8

I am trying display sitemap in my 404 page. Could you recommended ways how can I display sitemap in my 404 page?

At now I tried use a sitemap module. I created 404 node page and installed Drupal 8 sitemap module. Then I created sitemap block in content region. If I browse /404 page then only my node text is displayed, but not block where supposed to be sitemap.

Can I use some code?

If you go to /admin/config/system/site-information, on the bottom you can set your default 404 page. So you can create a page with your sitemap on in, or just put in the path of your current sitmemap.

You have to to configure page which is available in this location /admin/config/system/site-information there you have to give the link for 404 add /sitemap link. For reference i have attached Screen shoot. 在此处输入图片说明

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