猿问
下载APP

DEDE友情链接标签 flink 使用说明?

DEDE友情链接标签 flink 使用说明


弑天下
浏览 214回答 1
1回答

慕斯709654

DEDEcms的友情链接标签flink用于获取友情链接,其对应后台文件为"includetaglibflink.lib.php", &nbsp;图片 {dede:flink row='24' type='image' titlelen="24" typeid="0"} &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;底层标签 [field:link /] &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;{/dede:flink}&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp;文字 {dede:flink row='24' type='text' titlelen="24"&nbsp;&nbsp;typeid="0"} &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;底层标签 [field:link /] &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;{/dede:flink}&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp;实例&nbsp;运行代码无着色模式 点击可修改调试内容复制打印?&nbsp; &nbsp; &nbsp; &nbsp;<div&nbsp;class="flinkdtop"& gt;&nbsp;<span&nbsp;class="left&nbsp;clan">&nbsp;<strong>友情链接</strong>< /span>&nbsp;<span&nbsp;class="left"><a&nbsp;href="{dede:field&nbsp;name='phpurl' /}/flink_add.php"&nbsp;title="申请友情链接">申请友情链接</a></span>&nbsp;< a&nbsp;href="{dede:field&nbsp;name='phpurl'/}/flink.php"&nbsp;title="更多友情链 接"&nbsp;class="kmaore"></a>&nbsp;</div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp;<div&nbsp;class="lt_centflink">&nbsp;&nbsp;{dede:flink&nbsp;row='1000'} &nbsp;&nbsp; &nbsp; &nbsp; &nbsp;-&nbsp;[field:link&nbsp;/] &nbsp;&nbsp; &nbsp; &nbsp; &nbsp;{/dede:flink} &nbsp;&nbsp; &nbsp; &nbsp; &nbsp;</div>&nbsp;&nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<div &nbsp;class="flinkdtop"> <span class="left clan"> &nbsp;<strong>友情链接</strong></span> <span &nbsp;class="left"><a href="{dede:field name='phpurl'/}/flink_add.php" &nbsp;title="申请友情链接">申请友情链接</a></span> <a href="{dede:field &nbsp;name='phpurl'/}/flink.php" title="更多友情链接" class="kmaore"></a> &nbsp;</div> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp;&nbsp;<div class="lt_centflink">&nbsp;&nbsp;{dede:flink row='1000'} &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp;&nbsp;- [field:link /] &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp;&nbsp;{/dede:flink} &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp;&nbsp;</div> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp;CSS&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;.flinkdtop{ &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;line-height: 30px; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;background-color: #f5f5f5; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;height: 30px; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;border: 1px solid #dfdfdf; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;padding-right: 20px; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;padding-left: 20px; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;} &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;.lt_centflink{ &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;padding: 10px; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;border-right-width: 1px; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;border-bottom-width: 1px; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;border-left-width: 1px; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;border-right-style: solid; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;border-bottom-style: solid; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;border-left-style: solid; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;border-right-color: #dfdfdf; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;border-bottom-color: #dfdfdf; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;border-left-color: #dfdfdf; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;} &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;备注:&nbsp;row='24' 表示读取24个,如果row不设置,则默认为24,&nbsp;titlelen="24" 表示友情链接为文字形式,网站名称取24字符宽度,网站编码GBK则12个汉字,网站编码为UTF-8则为8个汉字.&nbsp;typeid="0"&nbsp;&nbsp;&nbsp;&nbsp;1 综合网站&nbsp;&nbsp;2 娱乐类&nbsp;&nbsp;3 教育类&nbsp;&nbsp; 4 计算机类&nbsp;&nbsp;5&nbsp;&nbsp;电子商务&nbsp;&nbsp;6 网上信息&nbsp;&nbsp; 7&nbsp;&nbsp;论坛类&nbsp;&nbsp;8 其它类型&nbsp;&nbsp;如果typeid="0"或者不填,则读取全部类型,&nbsp;注: &nbsp;后台代码 $wsql .= "And typeid = &nbsp;'$typeid'";&nbsp;&nbsp;所以typeid这个变量,只能使用一个数字,不支持1,2,3,4这种格式,如果想要支持1,2,3,4这种逗号间隔格式, 则需要改动includetaglibflink.lib.php文件,$wsql .= "And typeid = '$typeid'";&nbsp;&nbsp;改为 &nbsp;$wsql .= "And typeid in ($typeid)";type='image'&nbsp;&nbsp; 则&nbsp;&nbsp;[field:link /] 为连接+图片形式,&nbsp;type='text'&nbsp;&nbsp;则&nbsp;&nbsp;[field:link /] 为连接+文字形式, (责任编辑:天工开物)
打开App,查看更多内容
随时随地看视频慕课网APP
我要回答