请问织梦列表页如何调用dede_img
function GetOneImgUrl($img,$ftype=1){ if($img <> ''){ $dtp = new DedeTagParse(); $dtp->LoadSource($img); if(is_array($dtp->CTags)){ foreach($dtp->CTags as $ctag){ if($ctag->GetName()=='img'){ $width = $ctag->GetAtt('width'); $height = $ctag->GetAtt('height'); $imgurl = trim($ctag->GetInnerText()); $img = ''; if($imgurl != ''){ if($ftype==1){ $img .= $imgurl; } else{ $img .= '<img src="'.$imgurl.'" style="max-width:90%" height="'.$height.'" / alt="织梦列表页如何调用dede:img" >'; } } } } } $dtp->Clear(); return $img; } }
更新时间:2025-04-11 01:20:32
上一篇:请问网站备案修改是什么意思,网站备案信息如何进行修改
下一篇:请问织梦网站首页如何修改,轻松掌握织梦网站首页修改方法
转载请注明原文链接:https://www.muzicopy.com/suibi/7684.html