There are many ways to display the number of supply, enterprise, and information on the home page of the destoon implementation. Here we introduce direct call to the php program code for querying. Destoon's template supports php code, so we can query it directly in the template.
The implementation code is as follows:
<ul> {php $sellcount=$db->get_one("SELECT COUNT(*) AS num FROM ".$DT_PRE."sell WHERE status=3");} <li>There are a total of{$sellcount[num]}Supply</li> {php $company=$db->get_one("SELECT COUNT(*) AS num FROM ".$DT_PRE."member WHERE groupid>5");} <li>There are a total of{$company[num]}A company</li> {php $newcount=$db->get_one("SELECT COUNT(*) AS num FROM ".$DT_PRE."article_21 WHERE status=3");} <li>There are a total of{$newcount[num]}News</li> </ul>
How to display the current date on the page:
{date('Y-m-d',$DT_TIME)}