Home  >  Article  >  CMS Tutorial  >  How to batch replace all article sources and authors in DreamWeaver

How to batch replace all article sources and authors in DreamWeaver

藏色散人
藏色散人Original
2019-11-16 11:22:072280browse

How to batch replace all article sources and authors in DreamWeaver

How can Dreamweaver replace all article sources and authors in batches?

Dreamweaver DEDECMS method to batch replace the "source" and "author" of all articles

First step:

Open: dede (Backend directory) \templets\article_add.htm (publish ordinary template) and article_edit.htm (modify ordinary template)

Recommended learning: dedecms tutorial

Place:

<input name="source" type="text" id="source" style="width:160px" 
value="<?php echo $source; ?>" size="16"/>

and:

<input name="writer" type="text" id="writer" style="width:120px" 
value="<?php echo $arcRow["writer"]?>"><input name="selwriter" 
type="button" id="selwriter" value="选择" />

were changed to:

<input name="source" type="text" id="source" style="width:160px" value="" size="16"/>

and:

<input name="writer" type="text" id="writer" style="width:120px" value="织梦猫">
<input name="selwriter" type="button" id="selwriter" value="选择" />

(replace: "" above with your own source, " Replace "Dreamweaver" with your own author.)

Step 2: Log in to the backend--template--default template management--article_article.htm (article content page template)

:

<small>时间:</small>{dede:field.pubdate function="MyDate(&#39;Y-m-dH:i&#39;,@me)"/}
<small>来源:</small> {dede:field.source/} <small>作者:</small>{dede:field.writer/} 
<small>点击:</small><scriptsrcscriptsrc="{dede:field/}/count.php?view=yes&aid=
{dede:fieldname=&#39;id&#39;/}&mid={dede:field/}" type=&#39;text/javascript&#39;language="javascript">
</script>次</div& gt;<!-- /info -->

Changed to:

<small>时间:</small>{dede:field.pubdate function="MyDate(&#39;Y-m-dH:i&#39;,@me)"/}
<small>来源:</small> <small>作者:</small>织梦猫<small>点击:< /small>
<script src="{dede:fieldname=&#39;phpurl&#39;/}/count.php?view=yes&aid=
{dede:field/}&mid={dede:field/}" type=&#39;text/javascript&#39;language="javascript"></script>次</div>

(Replace: "" with your own source and "Dreamweaver Cat" with your own author.)

Then: Save

The third step: Content maintenance--select all--review

The third step: generate--one-click update website--update all--start update

You no longer need to select "source" and "author" when publishing new articles in the future

The above is the detailed content of How to batch replace all article sources and authors in DreamWeaver. For more information, please follow other related articles on the PHP Chinese website!

Statement:
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