-
摄影拍摄短视频类网站织...
-
道路护栏交通设施类网站...
-
环保设备研发制造类网站...
-
APP应用程序官网类网站织...
-
园林景观设计类网站织梦...
-
新媒体自媒体运营资讯类...
-
潮流资讯信息类网站织梦...
-
车辆机油工业润滑油类网...
-
水性工业漆类企业网站织...
-
LED显示屏中英双外贸类网...
-
园林绿化景观建设类网站...
-
中药药材百科资讯类网站...
-
企业公司行业通用类网站...
-
环保电动扫地车类网站织...
-
汽车配件类网站织梦模板...
-
办公学习教程资讯类网站...
-
网站建设营销类网站织梦...
-
灶具电器设备类网站织梦...
-
农业机械设备类网站织梦...
-
水上乐园设备类网站织梦...
打开/include/extend.func.php文件
在最下面加入这个方法
<span style="font-size:14px;" deep="13">function Getimgurls($aid,$num=4){global $dsql;$imgurls = $result = '';$imgrow = $dsql->GetOne( "Select imgurls From `mydiy_addonimages` where aid='$aid' ");$imgurls = $imgrow['imgurls'];if($imgurls != ''){$dtp = new DedeTagParse();$dtp->LoadSource($imgurls);$images = array();if(is_array($dtp->CTags)){foreach($dtp->CTags as $ctag){if($ctag->GetName() == 'img'){$row = array();$row['width'] = $ctag->GetAtt('width');$row['height'] = $ctag->GetAtt('height');$row['imgsrc'] = trim($ctag->GetInnerText());$row['text'] = $ctag->GetAtt('text');$images[] = $row;}}}$dtp->Clear();$i = 0;foreach($images as $row){if($i == $num) break;if($row['imgsrc'] != ''){$result .= "<li><a title='{$row['text']}' href='{$row['imgsrc']}'><img src='{$row['imgsrc']}' mid='{$row['imgsrc']}' big='{$row['imgsrc']}' width='70' height='70'></a></li>";}$i++;}return $result;}}</span>
前端调用
<span style="font-size:14px;">[field:id function=Getimgurls(@me,5)/]</span>




