Dedecms 5.5 實(shí)現(xiàn)自定義標(biāo)題處理,在 {dede:function}@me='64edu.com'.@me{/dede:function}中添加自定義的處理方法,就可以實(shí)現(xiàn)自定義dedecms5.5 5.3的接口處理效果
以下為引用的內(nèi)容:
{dede:sppage sptype='full'}{/dede:sppage} {dede:previewurl}http://tech.sina.com.cn/c/2003-04-18/18689.html{/dede:previewurl} {dede:keywordtrim}{/dede:keywordtrim} {dede:descriptiontrim}{/dede:descriptiontrim} {dede:item field='title' value='' isunit='' isdown=''} {dede:match}<title>[內(nèi)容]</title>{/dede:match} {dede:trim replace=""}_開 發(fā) 者_(dá)網(wǎng)上學(xué)園_科技時(shí)代_新浪網(wǎng){/dede:trim} {dede:function}@me='64edu.com'.@me{/dede:function} {/dede:item}{dede:item field='writer' value='' isunit='' isdown=''} {dede:match}{/dede:match} {dede:function}{/dede:function} {/dede:item}{dede:item field='source' value='' isunit='' isdown=''} {dede:match}{/dede:match} {dede:function}{/dede:function} {/dede:item}{dede:item field='pubdate' value='' isunit='' isdown=''} {dede:match}{/dede:match} {dede:function}{/dede:function} {/dede:item}{dede:item field='body' value='' isunit='1' isdown='1'} {dede:match}<tr><th class=f24><font color=#05006C>[內(nèi)容]<table width=565 border=0 cellspacing=0 cellpadding=0>{/dede:match} {dede:trim replace=''}<a([^>]*)>(.*)</a>{/dede:trim} {dede:trim replace=''}<!--(.*)-->{/dede:trim} {dede:trim replace=''}<img([^>]*)>{/dede:trim} {dede:trim replace=''}<object([^>]*)>(.*)</object>{/dede:trim} {dede:trim replace=''}<embed([^>]*)>(.*)</embed>{/dede:trim} {dede:trim replace=''}<iframe([^>]*)>(.*)</iframe>{/dede:trim} {dede:function}{/dede:function} {/dede:item}
測試5.5的采集規(guī)則
以下為引用的內(nèi)容:
復(fù)制代碼代碼如下:
BASE64:e2RlZGU6bGlzdGNvbmZpZ30NCntkZWRlOm5vdGVpbmZvIG5vdGVuYW1lPSJqYXZhc2NycHQiIGNoYW5uZWxpZD0iMSIgbWFjd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hdGNofQ0KICAgDQogICB7ZGVkZTpmdW5jdGlvbn17L2RlZGU6ZnVuY3Rpb259DQp7L2RlZGU6aXRlbX17ZGVkZTppdGVtIGZpZWxkPSdib2R5JyB2YWx1ZT0nJyBpc3VuaXQ9JzEnIGlzZG93bj0nMSd9DQogICB7ZGVkZTptYXRjaH08dHI+PHRoIGNsYXNzPWYyND48Zm9udCBjb2xvcj0jMDUwMDZDPlvlhoXlrrldPHRhYmxlIHdpZHRoPTU2NSBib3JkZXI9MCBjZWxsc3BhY2luZz0wIGNlbGxwYWRkaW5nPTA+ey9kZWRlOm1hdGNofQ0KICAge2RlZGU6dHJpbSByZXBsYWNlPScnfTxhKFtePl0qKT4oLiopPC9hPnsvZGVkZTp0cmltfQ0Ke2RlZGU6dHJpbSByZXBsYWNlPScnfTwhLS0oLiopLS0+ey9kZWRlOnRyaW19DQp7ZGVkZTp0cmltIHJlcGxhY2U9Jyd9PGltZyhbXj5dKik+ey9kZWRlOnRyaW19DQp7ZGVkZTp0cmltIHJlcGxhY2U9Jyd9PG9iamVjdChbXj5dKik+KC4qKTwvb2JqZWN0PnsvZGVkZTp0cmltfQ0Ke2RlZGU6dHJpbSByZXBsYWNlPScnfTxlbWJlZChbXj5dKik+KC4qKTwvZW1iZWQ+ey9kZWRlOnRyaW19DQp7ZGVkZTp0cmltIHJlcGxhY2U9Jyd9PGlmcmFtZShbXj5dKik+KC4qKTwvaWZyYW1lPnsvZGVkZTp0cmltfQ0KICAge2RlZGU6ZnVuY3Rpb259ey9kZWRlOmZ1bmN0aW9ufQ0Key9kZWRlOml0ZW19DQp7L2RlZGU6aXRlbWNvbmZpZ30=:END
以上就是本文的全部內(nèi)容,希望對大家的學(xué)習(xí)有所幫助,也希望大家多多支持素材無憂。
版權(quán)聲明: 本站資源均來自互聯(lián)網(wǎng)或會員發(fā)布,如果侵犯了您的權(quán)益請與我們聯(lián)系,我們將在24小時(shí)內(nèi)刪除!謝謝!
轉(zhuǎn)載請注明: 詳解Dedecms 5.5 實(shí)現(xiàn)自定義標(biāo)題處理(附采集規(guī)則)