{"id":233,"date":"2011-01-20T14:42:29","date_gmt":"2011-01-20T06:42:29","guid":{"rendered":"http:\/\/www.spendl.com\/?p=233"},"modified":"2015-06-25T22:53:17","modified_gmt":"2015-06-25T14:53:17","slug":"%e5%88%86%e4%ba%abdedecms%e7%bb%87%e6%a2%a6%e6%98%af%e6%80%8e%e4%b9%88%e5%9c%a8%e6%90%9c%e7%b4%a2%e9%a1%b5%e9%9d%a2%e8%b0%83%e5%87%ba%e5%bd%93%e5%89%8d%e6%98%be%e7%a4%ba%e9%a1%b9%e6%95%b0","status":"publish","type":"post","link":"https:\/\/www.spendl.com\/?p=233","title":{"rendered":"\u5206\u4eabdedecms(\u7ec7\u68a6)\u662f\u600e\u4e48\u5728\u641c\u7d22\u9875\u9762\u8c03\u51fa\u5f53\u524d\u663e\u793a\u9879\u6570"},"content":{"rendered":"<p>\u5728\u524d\u9762\u4e00\u7bc7\u6587\u7ae0\u201c<a title=\"\u5206\u4eabdedecms(\u7ec7\u68a6)\u662f\u600e\u4e48\u8c03\u7528\u641c\u7d22\u7ed3\u679c\u603b\u6570\" href=\"http:\/\/www.spendl.com\/?p=229\" target=\"_blank\">\u5206\u4eabdedecms(\u7ec7\u68a6)\u662f\u600e\u4e48\u8c03\u7528\u641c\u7d22\u7ed3\u679c\u603b\u6570<\/a>\u201d\u7684\u601d\u8def\u4e0a\u6211\u505a\u51fa\u4e86dedecms(\u7ec7\u68a6)\u5728\u641c\u7d22\u9875\u9762\u8c03\u51fa\u5f53\u524d\u663e\u793a\u9879\u6570\uff0c\u5206\u6790\u4e00\u4e0b\u3002<br \/>\n\u6548\u679c\u5982\u4e0b\u56fe\uff1a<br \/>\n<a href=\"http:\/\/www.spendl.com\/wp-content\/uploads\/2011\/01\/01.jpg\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-230\" title=\"\u5206\u4eabdedecms(\u7ec7\u68a6)\u662f\u600e\u4e48\u5728\u641c\u7d22\u9875\u9762\u8c03\u51fa\u5f53\u524d\u663e\u793a\u9879\u6570\" src=\"http:\/\/www.spendl.com\/wp-content\/uploads\/2011\/01\/01.jpg\" alt=\"\u5206\u4eabdedecms(\u7ec7\u68a6)\u662f\u600e\u4e48\u5728\u641c\u7d22\u9875\u9762\u8c03\u51fa\u5f53\u524d\u663e\u793a\u9879\u6570\" width=\"374\" height=\"290\" srcset=\"https:\/\/www.spendl.com\/wp-content\/uploads\/2011\/01\/01.jpg 374w, https:\/\/www.spendl.com\/wp-content\/uploads\/2011\/01\/01-300x232.jpg 300w\" sizes=\"(max-width: 374px) 100vw, 374px\" \/><\/a><\/p>\n<p>\u4e00\u3001<br \/>\n\u5728\uff1a<br \/>\n<span style=\"color: #0000ff;\">else  if($tagname==\u201dpagelist\u201d)<br \/>\n{<br \/>\n$list_len =  trim($ctag-&gt;GetAtt(\u201clistsize\u201d));<br \/>\nif($list_len==\u201d&#8221;)<br \/>\n{<br \/>\n$list_len =  3;<br \/>\n}<br \/>\n$this-&gt;dtp-&gt;Assign($tagid,$this-&gt;GetPageListDM($list_len));<br \/>\n} <\/span><br \/>\n\u4e0b\u9762\u52a0\u5165\u5982\u4e0b\u7ea2\u8272\u4ee3\u7801\uff1a<br \/>\n<span style=\"color: #ff0000;\">else if($tagname==&#8221;pagenow&#8221;)<br \/>\n{<br \/>\n$list_len = trim($ctag-&gt;GetAtt(&#8220;listsize&#8221;));<br \/>\nif($list_len==&#8221;&#8221;)<br \/>\n{<br \/>\n$list_len = 3;<br \/>\n}<br \/>\n$this-&gt;dtp-&gt;Assign($tagid,$this-&gt;GetPageNowDM($list_len));<br \/>\n}<br \/>\nelse if($tagname==&#8221;pagenows&#8221;)<br \/>\n{<br \/>\n$list_len = trim($ctag-&gt;GetAtt(&#8220;listsize&#8221;));<br \/>\nif($list_len==&#8221;&#8221;)<br \/>\n{<br \/>\n$list_len = 3;<br \/>\n}<br \/>\n$this-&gt;dtp-&gt;Assign($tagid,$this-&gt;GetPageNowsDM($list_len));<br \/>\n}<\/span><br \/>\n\u5373399\u884c\u3002<\/p>\n<p>\u4e8c\u3001<br \/>\n\u5728<br \/>\n<span style=\"color: #0000ff;\">\/\/&#8212;&#8212;&#8212;&#8212;&#8212;<br \/>\n\/\/\u83b7\u5f97\u5f53\u524d\u7684\u9875\u9762\u6587\u4ef6\u7684url<br \/>\n\/\/&#8212;&#8212;&#8212;&#8212;&#8212;-<\/span><br \/>\n\u524d\u9762\u52a0\u5165\u5982\u4e0b\u7ea2\u8272\u4ee3\u7801\uff0c\u5176\u5b9e\u4e5f\u5c31\u662fPageList\u4fee\u6539\u800c\u6765\u7684\uff1a<br \/>\n<span style=\"color: #ff0000;\">\/\/&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;-<br \/>\n\/\/\u641c\u7d22\u8f93\u51fa\u5f53\u524d\u9875\u9762\u524d\u9879\u6570<br \/>\n\/\/&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;-<br \/>\n\/\/\u83b7\u53d6\u52a8\u6001\u7684\u5206\u9875\u5217\u8868<br \/>\nfunction GetPageNowDM($list_len)<br \/>\n{<br \/>\nglobal $oldkeyword;<br \/>\n$pagenow = ($this-&gt;PageNo-1) * 10 + 1;<\/span><\/p>\n<p><span style=\"color: #ff0000;\">\/\/\u5f53\u7ed3\u679c\u8d85\u8fc7\u9650\u5236\u65f6\uff0c\u91cd\u8bbe\u7ed3\u679c\u9875\u6570<br \/>\nif($this-&gt;TotalResult &gt; $this-&gt;SearchMaxRc)<br \/>\n{<br \/>\n$totalpage = ceil($this-&gt;SearchMaxRc\/$this-&gt;PageSize);<br \/>\n}<\/span><\/p>\n<p><span style=\"color: #ff0000;\">$pagenow = &#8220;&#8221;.$pagenow.&#8221;&#8221;;<\/span><\/p>\n<p><span style=\"color: #ff0000;\">\/\/\u8f93\u51fa<\/span><\/p>\n<p><span style=\"color: #ff0000;\">$plist .= $pagenow;<\/span><\/p>\n<p><span style=\"color: #ff0000;\">return $plist;<br \/>\n}<br \/>\n\/\/\u7ed3\u675f<\/span><\/p>\n<p><span style=\"color: #ff0000;\">\/\/&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;-<br \/>\n\/\/\u641c\u7d22\u8f93\u51fa\u5f53\u524d\u9875\u9762\u540e\u9879\u6570<br \/>\n\/\/&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;-<br \/>\n\/\/\u83b7\u53d6\u52a8\u6001\u7684\u5206\u9875\u5217\u8868<br \/>\nfunction GetPageNowsDM($list_len)<br \/>\n{<br \/>\nglobal $oldkeyword;<br \/>\n$totalpage = ceil($this-&gt;TotalResult\/$this-&gt;PageSize);<\/span><\/p>\n<p><span style=\"color: #ff0000;\">$pagenows = $this-&gt;PageNo*10;<\/span><\/p>\n<p><span style=\"color: #ff0000;\">\/\/\u5f53\u7ed3\u679c\u8d85\u8fc7\u9650\u5236\u65f6\uff0c\u91cd\u8bbe\u7ed3\u679c\u9875\u6570<br \/>\nif($this-&gt;TotalResult &gt; $this-&gt;SearchMaxRc)<br \/>\n{<br \/>\n$totalpage = ceil($this-&gt;SearchMaxRc\/$this-&gt;PageSize);<br \/>\n}<\/span><\/p>\n<p><span style=\"color: #ff0000;\">if($this-&gt;PageNo!=$totalpage &amp;&amp; $totalpage&gt;1)<br \/>\n{<br \/>\n$pagenows = &#8220;&#8221;.$pagenows.&#8221;&#8221;;<br \/>\n}<br \/>\nelse<br \/>\n{<br \/>\n$pagenows = &#8220;&#8221;.$this-&gt;TotalResult.&#8221;&#8221;;<\/span><\/p>\n<p><span style=\"color: #ff0000;\">\/\/\u8f93\u51fa<\/span><\/p>\n<p><span style=\"color: #ff0000;\">$plist .= $pagenows;<\/span><\/p>\n<p><span style=\"color: #ff0000;\">return $plist;<br \/>\n}<br \/>\n\/\/\u7ed3\u675f<\/span><\/p>\n<p>\u4e09\u3001<br \/>\n\u5728\u8981\u663e\u793a\u7684\u5730\u65b9\u52a0\u5165<br \/>\n<span style=\"color: #ff0000;\">\u4ee5\u4e0b\u662f\u7b2c<strong><\/strong>{dede:pagenow  listsize=\u20194\u2032\/}<strong>&#8211;<\/strong>{dede:pagenows  listsize=\u20194\u2032\/}<strong><\/strong>\u9879<\/span><\/p>\n<p>GetPageNows\u7684\u4ee3\u7801\u52a0\u4e86\u5224\u65ad\uff0c\u5982\u679c\u670918\u9879\uff0c\u800c\u5f53\u524d\u663e\u793a\u7b2c\u4e00\u9875\u7684\u65f6\u5019\uff0c\u4ee3\u7801\u8f93\u51fa\u662f\u201c\u4ee5\u4e0b\u662f\u7b2c<strong>1-10<\/strong>\u9879\u201d\uff0c\u800c\u5f53\u524d\u663e\u793a\u7b2c\u4e8c\u9875\u7684\u65f6\u5019\u4ee3\u7801\u8f93\u51fa\u662f\u201c\u4ee5\u4e0b\u662f\u7b2c<strong>11-<span style=\"color: #800080;\">(\u603b\u9879\u6570)<\/span><\/strong>\u9879\u201d\u3002<\/p>\n<p>\u54c8\u54c8~\u7531\u4e8e\u6280\u672f\u95ee\u9898\uff0c\u641c\u7d22\u7ed3\u679c\u9875\u9762\u53ea\u80fd\u663e\u793a10\u4e2a\u7ed3\u679c\uff0c\u5982\u679c\u4e0d\u662f\u663e\u793a10\u4e2a\u7ed3\u679c\uff0c\u9879\u6570\u5c31\u4f1a\u662f\u9519\u8bef\u7684\u4e86\u3002\u56e0\u4e3a\u9879\u6570\u662f\u7528&#8221;$this-&gt;PageNo*10&#8243;\u505a\u51fa\u6765\u7684\u3002<\/p>\n<p>\u672c\u4eba\u83dc\u9e1f\uff0c\u5e0c\u671b\u6709\u9ad8\u624b\u80fd\u628a\u4ee3\u7801\u4fee\u6539\u6210\u66f4\u52a8\u6001\uff0c\u800c\u4e0d\u80fd\u9650\u5b9a\u53ea\u80fd\u663e\u793a10\u4e2a\u7ed3\u679c\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u5728\u524d\u9762\u4e00\u7bc7\u6587\u7ae0\u201c<a title=\"\u5206\u4eabdedecms(\u7ec7\u68a6)\u662f\u600e\u4e48\u8c03\u7528\u641c\u7d22\u7ed3\u679c\u603b\u6570\" href=\"http:\/\/www.spendl.com\/?p=229\" target=\"_blank\">\u5206\u4eabdedecms(\u7ec7\u68a6)\u662f\u600e\u4e48\u8c03\u7528\u641c\u7d22\u7ed3\u679c\u603b\u6570<\/a>\u201d\u7684\u601d\u8def\u4e0a\u6211\u505a\u51fa\u4e86dedecms(\u7ec7\u68a6)\u5728\u641c\u7d22\u9875\u9762\u8c03\u51fa\u5f53\u524d\u663e\u793a\u9879\u6570\uff0c\u5206\u6790\u4e00\u4e0b\u3002<\/p>\n<p>\u6548\u679c\u5982\u4e0b\u56fe\uff1a<\/p>\n<p><a href=\"http:\/\/www.spendl.com\/wp-content\/uploads\/2011\/01\/01.jpg\"><\/a><\/p>\n<p>\u4e00\u3001<\/p>\n<p>\u5728\uff1a<\/p>\n<p><span style=\"color: #0000ff;\">else<\/p>\n<p>if($tagname==\u201dpagelist\u201d)<\/p>\n<p>{<\/p>\n<p>$list_len =<\/p>\n<p>tr<\/p>\n<p><\/span><\/p>\n<div class=\"clear-float\"><\/div>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[52],"tags":[99,92,100,94,101,102],"views":4676,"_links":{"self":[{"href":"https:\/\/www.spendl.com\/index.php?rest_route=\/wp\/v2\/posts\/233"}],"collection":[{"href":"https:\/\/www.spendl.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.spendl.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.spendl.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.spendl.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=233"}],"version-history":[{"count":2,"href":"https:\/\/www.spendl.com\/index.php?rest_route=\/wp\/v2\/posts\/233\/revisions"}],"predecessor-version":[{"id":235,"href":"https:\/\/www.spendl.com\/index.php?rest_route=\/wp\/v2\/posts\/233\/revisions\/235"}],"wp:attachment":[{"href":"https:\/\/www.spendl.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=233"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.spendl.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=233"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.spendl.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=233"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}