Weaving dream Dedecms How to invoke the body body content and profile of a single article in the home page?

Source: Internet
Author: User

In the process of using Dede to build a station, we usually invoke the content on the homepage or List page, the official practice is to invoke the description content, but the invocation description has the corresponding disadvantage: the content of the call is limited, the default description is short, and after the article is modified, the description cannot be modified automatically, it needs to be modified manually. Here is a way to implement the first page or list page to invoke the body content of the article instead of description:

{dede:arclist row= ' 1 ' addfields= ' body ' idlist= ' typeid= ' 1 ' channelid= ' 1 '}

[Field:body function= ' Cn_substr (Html2text (@me), 4600) '/] ...

               
 {/dede:arclist}
If you need to call the HTML code inside the body please put function= ' Cn_substr (Html2text (@me), 4600) 'Delete!
here is the call introduction
{dede:arclistidlist= ' Specify the article ID number 'limit= ' 0,1 ' titlelen= 'infolen= ' + '}[field:title/] [verbose]{/dede:arclist}
Note:
1, addrields= "field one, field two ...", this is called the contents of the Body field.
2, Idlist: article number, call the content of the specified article, if it is called the list of articles can be idlist removed.
3, function= ' Cn_substr (Html2text (@me), +) 'Convert article content to text format, 600 can write it yourself. (the reserved format is: function= ' Cn_substr (@me, 600) ').
4, channelid= ' 1 ' model number, the article defaults to 1, check location: Backstage--core--content Model Management.
5, is "[Read More]" link CSS style, can be set in the CSS style sheet, no longer repeat.


Weaving dream Dedecms How to invoke the body body content and profile of a single article in the home page?

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.