Home >CMS Tutorial >DEDECMS >How to use the Mynews tag in the Dream Weaver System

How to use the Mynews tag in the Dream Weaver System

王林
王林Original
2019-11-07 09:30:182017browse

How to use the Mynews tag in the Dream Weaver System

Tag namemynews

##Function description:Site news call tag

Scope of application: global use

Basic syntax:

{dede:mynews row='' titlelen=''/}

Related functions:

File\include\taglib\mynews.lib.php Line 2

function lib_mynews(&$ctag,&$refObj)

Parameter description:

row='1' Call the number of news in the site

titlelen='24' News title length

Underlying template variable:

[field:title/]
[field:writer/]
[field:senddate function="strftime('%y-%m-%d %H:%M',@me)"/](时间)、[field:body/]

Usage example:

Let’s enter System background [Module]-[Site News Release], here we add 2 pieces of content according to the page requirements.

Next, we paste the following content in [Template]-[Global Mark Test] in the system background:

{dede:mynews row=2}
标题:[field:title/] 发布日期:[field:senddate function="strftime(&#39;%y-%m-%d %H:%M&#39;,@me)"/]<br/>
新闻内容:[field:body/]<br />
<hr/>
{/dede:mynews}

How to use the Mynews tag in the Dream Weaver System

Recommended tutorial:

dedecms Tutorial

The above is the detailed content of How to use the Mynews tag in the Dream Weaver System. 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