<ruby id="bdb3f"></ruby>

    <p id="bdb3f"><cite id="bdb3f"></cite></p>

      <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
        <p id="bdb3f"><cite id="bdb3f"></cite></p>

          <pre id="bdb3f"></pre>
          <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

          <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
          <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

          <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                <ruby id="bdb3f"></ruby>

                ??一站式輕松地調用各大LLM模型接口,支持GPT4、智譜、豆包、星火、月之暗面及文生圖、文生視頻 廣告
                [返回目錄](index.html)#### [標簽使用](pctag_index.html) —— [功能模塊](pctag_model_index.html) —— [內容模塊](function_content.html) ##### 一、內容模塊 內容模塊PC標簽調用說明 *模塊名:*content 模塊提供的可用操作 操作名 說明lists 內容數據列表relation 內容相關文章hits 內容數據點擊排行榜category 內容欄目列表position 內容推薦位列表- - - - - - ###### 1.position操作說明如下: *內容推薦位列表(position):* 可用參數: 參數名 是否必須 默認值 說明 posid 是 null 推薦位ID catid 否 null 調用欄目ID thumb 否 0 是否僅必須縮略圖 where 否 null sql語句(可與其他條件組合) order 否 null 排序類型 num 是 null 數據調用數量 代碼例子: ``` <pre class="brush:xml">{pc:content ?action="position" posid="2" order="listorder DESC" num="4"} <ul> {loop $data $key $val} <li><a href="{$val['url']}">{$val['title']}</a></li> {/loop} </ul> {/pc} ``` 返回參數如下表: 字段 類型 空 默認 注釋titlechar(80) 否*NULL* 推薦位標題urlchar 否*NULL* 推薦位鏈接地址inputtimeint(10) 否*NULL* 推薦位發布時間thumb char 是*NULL* 推薦位縮略圖其他不定 是 根據模型所設置的加入到推薦位中字段名稱- - - - - - ###### 2.內容列表(lists): 可用參數: 參數名 是否必須 默認值 說明 catid 否 null 調用欄目ID where 否 null sql語句的where部分 thumb 否 0 是否僅必須縮略圖 order 否 null 排序類型 num 是 null 數據調用數量 moreinfo 否 0 是否調用副表數據 提醒:*從PHPCMS V9 Beta 20101105版本開始支持moreinfo參數屬性,本參數表示在返回數據的時候,會把副表中的數據也一起返回。一個內容模型分為2個表,一個主表一 個副表,主表中一般是保存了標題、所屬欄目等等短小的數據(方便用于索引),而副表則保存了大字段的數據,如內容等數據。在模型管理中新建字段的時候,是 允許你選擇存入到主表還是副表的(我們推薦的是,把不重要的信息放到副表中)。想要在列表中調取副表的數據就需要在PC標簽中使用moreinfo這個屬 性。* 代碼例子: ``` <pre class="brush:xml">{pc:content ?action="lists" catid="2" order="id DESC" num="4"} <ul> {loop $data $key $val} <li> <a href="{$val['url']}">{$val['title']}</a></li> {/loop} </ul> {/pc} ``` where用法: ``` <pre class="brush:xml">{pc:content ?action="lists" catid="2" where="`thumb`!='' AND `status`=99" order="id DESC" num="4"} <ul> {loop $data $key $val} <li> <a href="{$val['url']}">{$val['title']}</a></li> {/loop} </ul> {/pc} ``` 返回參數如下表: 字段 類型 空 默認 注釋titlechar(80) 否*NULL* 標題urlchar 否*NULL* 鏈接地址inputtimeint(10) 否*NULL* 發布時間thumb char 是*NULL* 縮略圖其他不定 是 其他模型字段- - - - - - ###### 3.點擊排行榜(hits): 可用參數: 參數名 是否必須 默認值 說明 catid 否 null 調用欄目ID day 否 0 調用多少天內的排行 order 否 null 排序類型(本月排行- monthviews DESC 、本周排行 - weekviews DESC、今日排行 - dayviews DESC) num 是 null 數據調用數量 代碼例子: ``` <pre class="brush:xml">{pc:content ?action="hits" catid="2" order="weekviews DESC" num="10"} <ul> {loop $data $key $val} <li> <a href="{$val['url']}">{$val['title']}</a></li> {/loop} </ul> {/pc} ``` 返回參數如下表: 字段 類型 空 默認 注釋titlechar(80) 否*NULL* 推薦位標題urlchar 否*NULL* 推薦位鏈接地址inputtimeint(10) 否*NULL* 推薦位發布時間thumb char 是*NULL* 推薦位縮略圖其他不定 是 其他模型字段- - - - - - ###### 4.相關文章(relation): 可用參數: 參數名 是否必須 默認值 說明 catid 否 null 調用欄目ID relation 否 $relation 無需更改 keywords 否 null 內容頁面取值:$rs\[keywords\] num 是 null 數據調用數量 代碼例子: ``` <pre class="brush:xml">?{pc:content action="relation" relation="$relation" catid="$catid" num="5" keywords="$rs[keywords]"} {loop $data $r} <li>·<a href="{$r[url]}" target="_blank">{$r[title]}</a><span>({date('Y-m-d',$r[inputtime])})</span></li> {/loop} {/pc} ``` 返回參數如下表: 字段 類型 空 默認 注釋titlechar(80) 否*NULL* 標題urlchar 否*NULL* 鏈接地址inputtimeint(10) 否*NULL* 發布時間thumb char 是*NULL* 縮略圖其他不定 是 其他模型字段- - - - - - ###### 5.欄目列表(category): 可用參數: 參數名 是否必須 默認值 說明 catid 否 0 調用該欄目下的所有欄目 ,默認0,調用一級欄目 $siteid 否 1 默認調用系統站點 order 否 null 排序方式、一般按照listorder ASC排序,即欄目的添加順序 代碼例子: ``` <pre class="brush:xml">?{pc:content action="category" catid="0" num="25" siteid="$siteid" order="listorder ASC"} {loop $data $r} <li><a href="{$r[url]}"><span>{$r[catname]}</span></a></li> {/loop} {/pc} ``` 返回參數如下表: 字段 類型 默認值 說明 catidsmallint *無* 欄目IDsiteidtinyint(3) 0 站點IDmodulevarchar(15) *無* 模塊IDtypetinyint(1) 1 欄目類型IDmodelidtinyint(5) 5 模型IDparentidsmallint(5) 5 上級父欄目arrparentidvarchar(255) *無* 所有父欄目childtinyint(1) 0 子欄目arrchildidmediumtext *無* 所有子欄目catnamevarchar(30) *無* 欄目名稱imagevarchar(100) *無* 欄目圖片descriptionmediumtext *無* 欄目描述parentdirvarchar(100) *無* 父欄目目錄catdirvarchar(30) *無* 欄目目錄urlvarchar(100) *無* 欄目鏈接itemsmediumint(8) 0 欄目內容數hitsint(10) 0 點擊數settingmediumtext *無* 欄目設置listordersmallint(5) 0 排序ismenutinyint(1) 0 是否顯示sethtmltinyint(1) 0 是否生成到根目錄lettervarchar(30) *無* 欄目拼音 [返回目錄](index.html) 上海盛大網絡發展有限公司 c 2006 - 2011 B2-20040053. 問題和建議請反饋至:http://bbs.phpcms.cn
                  <ruby id="bdb3f"></ruby>

                  <p id="bdb3f"><cite id="bdb3f"></cite></p>

                    <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
                      <p id="bdb3f"><cite id="bdb3f"></cite></p>

                        <pre id="bdb3f"></pre>
                        <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

                        <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
                        <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

                        <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                              <ruby id="bdb3f"></ruby>

                              哎呀哎呀视频在线观看