Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

The method of calling Custom member Model member Information in dedecms

2025-04-14 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/02 Report--

Editor to share with you the method of dedecms calling custom membership model membership information, I believe that most people do not know much about it, so share this article for your reference, I hope you can learn a lot after reading this article, let's go to know it!

How does dedecms call the membership information of the custom membership model?

Dedecms uses memberlist tags to call the membership information of a custom membership model.

Dedecms uses the memberlist tag to call the member information of the custom membership model. This problem has been found for a long time. The official forum has asked questions, and Baidu has searched directly to find out how to solve it today.

Different membership models are distinguished by the mtype field in the table: _ member. The steps are as follows:

Open include\ taglib\ memberlist.lib.php, as follows:

Find the following code:

$attlist= "row | 6 Magi iscommend | 0 Magi orderby | logintime,signlen | 50"

Modified to:

$attlist= "row | 6 Magi iscommend | 0 Magi orderby | logintime,signlen | 50 Magi type"

Find the following code:

If ($iscommend > 0) $wheresql. = "AND mb.matt='$iscommend'"

Add the following:

If ($type! = ") $wheresql. =" And mb.mtype='$type' "

The above operations can also be directly modified through the website background, step: background-template-template management-tag source code management, find: memberlist.lib.php, click on the following edit to modify.

The tag is called with: type=' member model name', called. Example:

{dede:memberlist type=' Enterprise 'row='8' signlen=18} [field:uname/] {/ dede:memberlist} these are all the contents of dedecms's method of calling custom membership model membership information. Thank you for reading! I believe we all have a certain understanding, hope to share the content to help you, if you want to learn more knowledge, welcome to follow the industry information channel!

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report