Zblogphp calls multiple methods with arbitrarily specified article IDs

22:57:04, July 25, 2017 Yidian Yidi three thousand three hundred and seventy-six

For some CMS style topics, home page content arrangement is a headache. There is no other way to mark articles in the zblogphp system except top. If you want to display specified articles in specific areas, you need to do it yourself. Today, let's share the method of zblogphp calling multiple arbitrary article IDs. The code is as follows:

 {php}         $array = explode(',','1,2,3,4'); {/php}         {foreach $array as $hotid}         {$related=GetPost((int)$hotid)}         <li><a href="{$related.Url}" target="_blank">{$related.Title}</a></li>         {/foreach}

The above 1, 2, 3, and 4 are the article IDs. Multiple entries can be separated by English commas and can be specified arbitrarily.

Excellent, really powerful! Well, we must encourage~

Reward one
account number: mxy310@163.com [Copy]
account number: seventy-seven million nine hundred and forty thousand one hundred and forty [Copy]