Home > CMS Tutorial > DEDECMS > body text

How to solve the problem of senddate being later than pubdate in dede5.7

藏色散人
Release: 2019-12-16 09:59:33
Original
2398 people have browsed it

How to solve the problem of senddate being later than pubdate in dede5.7

How to solve the problem of senddate being later than pubdate in dede5.7?

With the requirements of "Baidu Search Landing Page Time Factor Specification", web pages need to add the standardized release time and publishing time, and it is accurate to the second. Many friends have used DEDE to build websites. , there are two times, senddate and pubdate, in DreamWeaver. One is the release time, and the other can be regarded as the update time.

Recommended study: 梦Weavercms

But after we publish the article, we will find that the senddate is later than the pubdate time. This is a minor problem, that is It is theoretically unreasonable to tell search engines that the release time is later than the update time. How to solve this problem?

How to solve the problem of senddate being later than pubdate in dede5.7

After testing, the editor modified article_add.php under dede and we searched for "$senddate"

How to solve the problem of senddate being later than pubdate in dede5.7

us Change: $senddate=time(); to $senddate = GetMkTime($pubdate); Save

How to solve the problem of senddate being later than pubdate in dede5.7

After modification, we will find out when we re-publish an article, When publishing for the first time, the time of senddate and pubdate are the same. This is correct. When publishing for the first time, the two times should be the same. When we modify the newly published article, we will find that the pubdate is updated. It has become the latest modified time, and senddate has not changed. This solves the requirements of the "Baidu Search Landing Page Time Factor Specification".

The above is the detailed content of How to solve the problem of senddate being later than pubdate in dede5.7. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template