<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、智譜、豆包、星火、月之暗面及文生圖、文生視頻 廣告
                > #### 多條件搜索 > 適用范圍:全站任意地方均可使用 > 標簽作用:用于執行站內搜索功能 #### **1、最簡單的搜索示例** ``` <form action="{shanke:scaction}" ?method="get"> ??關鍵字:<input type="text" name="keyword" > ?<button type="submit">搜索</button> </form> ``` > ? ? 表單提交方式為get. > 使用說明: {shanke:scaction} 為搜索提交地址 注意:表單提交方式為get,此表單默認匹配title標題字段 #### **2、定義搜索字段示例** ``` <form action="{shanke:scaction}" ?method="get"> 關鍵字:<input type="text" name="keyword" > <input type="hidden" name="field" value="title" > <button type="submit">搜索</button> </form> 或: <form action="{shanke:scaction}" ?method="get"> <select name="field"> ?<option value="title">內容標題</option> ?<option value="content">內容詳情</option> </select> 關鍵字:<input type="text" name="keyword" > <button type="submit">搜索</button> </form> ``` > 通過添加隱藏域傳遞field值來控制搜索的字段,也可以同時設置多個字段,如: value="title|content" ,當然這只是方式之一,后面還有! #### **3、定義更多搜索條件示例** ``` <form action="{shanke:scaction}" ?method="get"> 關鍵字:<input type="text" name="keyword" > ?<input type="hidden" name="field" value="title" > <input type="hidden" name="scode" value="2,3" > <button type="submit">搜索</button> </form> ``` > 這里只定義搜索的字段和搜索的分類,其實你可以定義更多數據庫中任意可用的字段。如author為admin的:name="author" value="admin",當然你可以使用非隱藏域,那么就相當于綜合搜索類型。 > 如果需要定義的scode分類有多個,可以用逗號隔開,同時需要注意,如果表單傳遞的分類和字段無效時,要考慮結果頁循環是否做了限制。 如果有多個搜索表單想定義不同的結果頁模板,那么可以傳遞searchtpl字段來定義模板頁,如: ``` <input type="hidden" name="searchtpl" value="test.html" > ``` #### **4、多條件綜合搜索示例** ``` <form action="{shanke:scaction}" ?method="get"> 內容:<input type="text" name="content" > 標題:<input type="text" name="title" > 作者:<input type="text" name="author" > <input type="hidden" name="scode" value="2,3" > <button type="submit">搜索</button> </form> ``` ????這里自定義了三個字段,其實你可以定義更多數據庫中任意可用的字段。 如果URL采用兼容模式,這時候搜索應該使用POST,或者在首行添加隱藏域,`<input type="hidden" name="search" >` #### **5、搜索結果列表** ``` {shanke:search} <a href="[search:link]">[search:title]</a> {/shanke:search} ``` 使用說明: > 搜索結果頁面使用模板search.html > num=\* ?每頁數量,非必填,用于控制分頁大小 > order=\* ? 排序方式,非必填,用于輸出內容的排序方式,可選:date、sorting、istop、isrecommend、isheadline、visits、likes、oppose等字段,其中sorting為按后臺填寫的排序,122版本開始支持自定義模式,如:order='date desc,id desc' 、order='sorting desc,id desc',還支持random隨機排序 > scode=\* ?分類編碼,非必填,加前面說的方式,此作為第二種限制搜索分類的方式,多個分類用逗號隔開,如: scode='2,3,4' > field=\* 字段限制,非必填,在使用了keyword時用于限定匹配的數據庫字段,多個字段用豎線隔開即可,如:field='title|content' > filter=\*|x,y 數據過濾,非必填,用于對列表內容進行過濾篩選,如:filter=title|ASP,PHP 只顯示標題含有ASP和PHP的內容 > fuzzy=\* ?是否模糊匹配,非必填,可選1或0,1時為默認的模糊匹配,0則關閉 搜索結果默認執行分頁,使用內容列表的分頁代碼即可. #### **6、搜索結果列表可用標簽** ?獲取當前搜索內容:{shanke:keyword}? ? ?對搜索結果關鍵字進行標紅 mark=1 ,如:\[search:title mark=1\]; [search:n]序號從0開始 [search:i]序號從1開始 [search:id]編號 [search:scode]分類編碼 [search:subscode]副分類編碼 [search:sortname]分類名稱 [search:subsortname]副分類名稱 [search:sortlink]分類鏈接 [search:subsortlink]副分類鏈接 [search:title]標題 [search:titlecolor]標題顏色 [search:subtitle]副標題 [search:author]作者 [search:source]來源 [search:link]鏈接 [search:outlink]外部鏈接 [search:date]發布日期 [search:ico]縮略圖 [search:pics]多圖 [search:content]內容 [search:enclosure]附件 [search:enclosuresize]附件大小 [search:keywords]關鍵詞 [search:description]描述 [search:istop]是否置頂 [search:isrecommend]是否推薦 [search:isheadline]是否頭條 [search:visits]訪問數量 [search:likes]點贊數量 [search:oppose]反對數量 [search:likeslink]點贊鏈接 [search:opposelink]反對鏈接
                  <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>

                              哎呀哎呀视频在线观看