Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to use dede to remove index.html

2025-02-24 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/01 Report--

This article shows you how to use dede to remove index.html, the content is concise and easy to understand, can definitely brighten your eyes, through the detailed introduction of this article, I hope you can get something.

After Dede generates the home page by default, there will be an extra index.html after the link on the home page. According to officials, this is conducive to website optimization.

But this index.html is uncomfortable no matter how it looks, and it is not conducive to the unification of the home page url in seo. Because the url of my site turns to unified with. Htaccess is www, and it ends with .com.

Therefore, in order not to allow the weight of the home page to be decentralized, but also for aesthetic considerations, the index.html of the home page of dede should be removed.

The method of removing index.html from the home page of dede given on the Internet is as follows:

1. Replace the content generation dynamics of index.php according to the official update instructions

If you do not need to generate HTML on the home page, replace index.php with the following code

Of course, not if you want to generate html.

two。 Delete the index.php file under the CMS root directly

This method seems to be the simplest, but I tried it myself without success. And there is no way to use dynamic browsing after deletion.

3. Use .htaccess files

At present, this method is used and the experiment is successful.

The methods are as follows:

Add the following code to .htaccess in the root directory:

DirectoryIndex index.html index.php index.htm

It's that simple.

4. Set the default home page order in the host: bring index.html to the front.

The setting method is different depending on the host. I won't go into details.

The above is how to use dede to remove index.html. Have you learned any knowledge or skills? If you want to learn more skills or enrich your knowledge reserve, you are welcome to follow the industry information channel.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report