admin管理员组

文章数量:1323225

when I activated the theme. it is only one page. the navbar links are Home #About #Services #Contact

the problem when I make template name on the frontpage

<?php

/* Template Name: front-page */ 
get_header(); ?>

then I created a page from the dashboard called Home

it added slug /home at the end of the url

so the website url differed because of this homepage template. it added the home slug the url. I need to remove /home slug. just want the same link without changing.

what should I do, please? to make template for homepage without changing the url of the website?

and many thanks in advance.

when I activated the theme. it is only one page. the navbar links are Home #About #Services #Contact

the problem when I make template name on the frontpage

<?php

/* Template Name: front-page */ 
get_header(); ?>

then I created a page from the dashboard called Home

it added slug /home at the end of the url

so the website url differed because of this homepage template. it added the home slug the url. I need to remove /home slug. just want the same link without changing.

what should I do, please? to make template for homepage without changing the url of the website?

and many thanks in advance.

Share Improve this question asked Oct 3, 2020 at 16:01 socialsocial 713 silver badges9 bronze badges
Add a comment  | 

2 Answers 2

Reset to default 0

Check this article on how to create a static homepage in WordPress https://wordpress/support/article/creating-a-static-front-page/

You can change /* Template Name: front-page */ and use page ID instead of a title.

本文标签: permalinksHomepage template and url changed