


A tutorial on how to push the Dreamweaver sitemap map to Baidu in real time, Dreamweaver sitemap_PHP tutorial
Tutorial on pushing the Dreamweaver sitemap map to Baidu in real time, Dreamweaver sitemap
Before, Dreamweaver had a set of plug-ins for actively pinging Baidu, but later it became unusable. In the end Baidu has launched a real-time push link address to Baidu. This is much more convenient and easier to use than sitemap, and it can also ensure the originality of the article. Below, I read the relevant information and wrote an article based on Baidu's interface to push the sitemap map to Baidu in real time. Share the solution with everyone.
I have written two methods about Baidu real-time push of Dreamweaver, you can choose by yourself:
1. Manually create a file and access this file every day to push all the articles of the day to the Baidu search engine. Create a tuisong.php under the root directory and after accessing it, the Baidu interface results will be returned
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 |
|
View push feedback
Push successful
The status code is 200 and the following fields may be returned:
Field Is it required? Parameter type Description
success is int the number of urls successfully pushed
remain is int the remaining number of pushable URLs on the day
not_same_site No array List of URLs that have not been processed because they are not the URLs of this site
not_valid No array Illegal url list
Successful return example:
Copy code The code is as follows:
{
"remain":4999998,
"success":2,
"not_same_site":[],
"not_valid":[]
}
Push failed
The status code is 4xx, and the return fields are:
Field Type Description
error is an int error code, the same as the status code
message is string error description
Failure return example:
Copy code The code is as follows:
{
"error":401,
"message":"token is not valid"
}
2. The second way is to publish an article, just like Baidu pushes it once. This is more convenient, and this is what I use
Open the article_add.php file in Dreamweaver Backend. Find almost 262 lines
Note:
If your system settings-》Core Options
If it is direct. Add the following code, otherwise pay attention to the following tips
1 2 3 4 5 6 7 8 9 10 11 12 13 14 |
|
It’s OK. If you want to see whether the addition is successful, you can modify the following one or two lines of code
Copy code The code is as follows:
Please select your subsequent operation ".$result.$urls[0].":
result refers to the results returned by Baidu, and urls refers to the URLs you push.
It’s basically OK. If you want the article to be pushed when you modify it, just modify article_edit.php like I did above.
The above is the entire content of this article, I hope you all like it.

Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

Video Face Swap
Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Article

Hot Tools

Notepad++7.3.1
Easy-to-use and free code editor

SublimeText3 Chinese version
Chinese version, very easy to use

Zend Studio 13.0.1
Powerful PHP integrated development environment

Dreamweaver CS6
Visual web development tools

SublimeText3 Mac version
God-level code editing software (SublimeText3)

Hot Topics

UniApp implements real-time push techniques for push messages and notifications In modern society, the push message and notification functions of mobile applications are becoming more and more important. As users have higher and higher demands for real-time information, developers are constantly exploring how to implement real-time push in mobile applications. As a cross-platform development framework, UniApp provides developers with a simple and efficient way to implement real-time push messages and notifications. UniApp is a cross-platform development framework developed based on Vue.js. It supports the integration of a set of codes into

How to implement real-time data push function in MongoDB MongoDB is a document-oriented NoSQL database, which is characterized by high scalability and flexible data model. In some application scenarios, we need to push data updates to the client in real time in order to update the interface or perform corresponding operations in a timely manner. This article will introduce how to implement the real-time push function of data in MongoDB and give specific code examples. There are many ways to implement real-time push functionality, such as using polling, long polling, Web

How to import css into DreamWeaver: 1. Place the HTML template file in the "templets" folder; 2. Change the suffix of the HTML file to ".htm"; 3. Add "{dede:" in front of the original style path: global.cfg_templets_skin/}" can be used.

How to use Vue and Axios to achieve real-time push and update of data Introduction: In modern web applications, real-time data push and update has become a common requirement. As a popular front-end framework, Vue can easily interact with the back-end for data interaction and real-time updates. Axios is a Promise-based HTTP library that can easily send asynchronous requests. This article will introduce how to use Vue and Axios to achieve real-time push and update of data. 1. Overview of realizing real-time push of data and

Decryption of real-time push and message broadcast technology developed by Swoole With the rapid development of the Internet, real-time push and message broadcast technology play an increasingly important role in various network applications. Swoole, as an efficient and development-friendly PHP extension, provides developers with powerful real-time communication capabilities. This article will introduce the real-time push and message broadcast technology in Swoole development functions, and provide some code examples. What is Swoole? Swoole is a coroutine concurrent network based on PHP language

PHPWebSocket development technology sharing: The best strategy to implement real-time push function With the rapid development of the Internet and the gradual increase in user demand for real-time information, real-time push has become an indispensable part of modern Web applications. As an open standard, WebSocket technology provides a two-way communication capability, making it an ideal choice for realizing real-time push functions. This article will share some of the best strategies for PHP WebSocket development to help developers implement real-time push functions quickly and efficiently.

Java Development: Using WebSocket to Implement Real-Time Push Function Introduction: In modern web applications, the transmission of real-time data is becoming more and more important. WebSocket is a protocol that provides two-way real-time communication between client and server, which can transfer data without refreshing the page. This article will introduce how to use Java language and Spring framework to implement real-time push function through WebSocket, and provide specific code examples. Environment preparation: First, we need to build J

It is a common situation to encounter problems when installing Dreamweaver. One of the possible problems is that php7.0 cannot be successfully installed. In this article, we will explain how to solve this problem.
