Methods/steps before modifying the background
Dreamweaver background also has the function of automatically generating maps, but it only generates column directories, which can't realize the Sitemap map we want. Moreover, many people often use other map generation tools and have to upload them again every day, which is very troublesome. Then, Yudou provides a background generation method of xml and html map formats, and the required files are listed in the download link at the back of the article.
Before modification, the dream weaving column generated in the background is shown in the following figure:
Start modifying files and uploading files.
Next, open the downloaded file, the most important step: open all the format documents in DW except php file, and replace www.abc.com as your domain name in batches (note that it is all). Put the sitemap.xml and sitemap.xml files in the template directory of the website (default). For example, if my website template style is abc, then these two files will be uploaded to /templates/abc/ in the root directory of the website. Then, when you return to the root directory, call the dede folder. (Note: It is the background login directory of Zhimeng. Some companies may have changed this name. Open a folder when the login suffix is in the background). First, put the modified inc_menu.php file into the inc folder, and put the three template files, namely makehtml_homepage.htm, makehtml_htmlpage.htm and makehtml_XMLpage.htm, into the template directory, that is, dede/templets (prompt for repetition, direct overwrite). Finally, put the remaining two php files into dede.
Go back to the background to generate the dream-weaving column, and you will find that there are two more options for generating maps. After clicking, it is easy to generate xml and html diagrams of the website. draw
Baidu Ping push function
Because ping push can only be realized through rss subscription, before Baidu push function is realized, you only need to add a dream-weaving rss subscription function, open the "all-site Rss" in the downloaded "DEDECMS Baidu Ping Plug-in All-site Rss", upload the php file directly to the root directory, and put rss.htm in the templetsdefault in the template directory currently selected by your website (default is default).
After completion, directly visit your website domain name name.rss.php, and you can see that your website subscription function has been realized.
Without adding Baidu Ping function, reading articles will be displayed in the background as shown in the figure (before Ping modification):
Next is the more important Baidu Ping push function. Upload the files in the "Baidu ping/dede" folder after replacing the domain names in batches to the corresponding folder and overwrite them.
Then we must concentrate on revising this document of ping.php.
1. Find the penultimate line in ping.php:
$arc=newPing (the title of your website, get_arcurl($id), get_domain (), your website /RSS. PHP);
This line means:
$arc=newPing (website name, get_arcurl($id), get_domain (), RSS address);
Just modify it yourself.
2. Search: $conn=mysql_connect
You will find two.
$ name =;
$conn=MySQL_connect (database connection, account number, database password);
Many people don't know their database information here. You can download common.inc.php from the data directory in your ftp, and you can clearly see all the database information when you open it. Compare and modify ping.php's database link information and upload it to the root directory of the website.
Refresh the background article management bar as shown in the figure (ping modification):
four
Realize the push function.
At this point, we have realized two functions that have not been available since Dreamweaver. The test has not found any bugs so far, and it has no impact on the website.