{template "content","header"} <!-- 开始取出字段--------------------------------------------- --> {pc:get sql="SELECT * FROM `v9_model_field` where `field`='fangshi' and `modelid`='3'" return="data"} <?php $optionsn=''; eval("\$setting_arr =".$data[0]['setting'].";"); $optionsn=explode("\n",$setting_arr['options']); $fangshi_array=array(); //修改这个地方 foreach( $optionsn as $kk=>$vv){ $optionsn_vv=explode("|",$vv); $fangshi_array[trim($optionsn_vv[1])]=trim($optionsn_vv[0]); //修改这个地方 } ?> {/pc} {pc:get sql="SELECT * FROM `v9_model_field` where `field`='paytype' and `modelid`='3'" return="data"} <?php $optionsn=''; eval("\$setting_arr =".$data[0]['setting'].";"); $optionsn=explode("\n",$setting_arr['options']); $paytype_array=array(); //修改这个地方 foreach( $optionsn as $kk=>$vv){ $optionsn_vv=explode("|",$vv); $paytype_array[trim($optionsn_vv[1])]=trim($optionsn_vv[0]); //修改这个地方 } ?> {/pc} {pc:get sql="SELECT * FROM `v9_model_field` where `field`='housetype' and `modelid`='3'" return="data"} <?php $optionsn=''; eval("\$setting_arr =".$data[0]['setting'].";"); $optionsn=explode("\n",$setting_arr['options']); $housetype_array=array(); //修改这个地方 foreach( $optionsn as $kk=>$vv){ $optionsn_vv=explode("|",$vv); $housetype_array[trim($optionsn_vv[1])]=trim($optionsn_vv[0]); //修改这个地方 } ?> {/pc} {pc:get sql="SELECT * FROM `v9_model_field` where `field`='dingshi' and `modelid`='3'" return="data"} <?php $optionsn=''; eval("\$setting_arr =".$data[0]['setting'].";"); $optionsn=explode("\n",$setting_arr['options']); $dingshi_array=array(); //修改这个地方 foreach( $optionsn as $kk=>$vv){ $optionsn_vv=explode("|",$vv); $dingshi_array[trim($optionsn_vv[1])]=trim($optionsn_vv[0]); //修改这个地方 } ?> {/pc} <!-- 结束取出字段--------------------------------------------- --> 织梦模板,phpcms模板免费下载 http://www.bbscms.net <!-- 开始拼装where --> <?php $where=""; if(!empty($_GET['fangshi'])){ $where.="`fangshi` = '".$_GET['fangshi']."' AND "; } if(!empty($_GET['paytype'])){ $where.="`paytype` = '".$_GET['paytype']."' AND "; } if(!empty($_GET['housetype'])){ $where.="`housetype` = '".$_GET['housetype']."' AND "; } if(!empty($_GET['dingshi'])){ $where.="`dingshi` = '".$_GET['dingshi']."' AND "; } $where.=1; ?> <!-- 结束拼装where --> <!--main--> <div class="main photo-channel"> <div class="crumbs"><a href="{siteurl($siteid)}">首页</a><span> > {catpos($catid)}</div> <div class="bk10"></div> <style> .udiv{ margin-bottom:10px;} .ucurent{ background:#FF0; padding:2px; font-weight:bold;} </style> <div class="udiv"><strong>租房方式</strong>: <span><a href="{APP_PATH}index.php?m=content&c=index&a=lists&catid={$catid}&paytype={$_GET['paytype']}&housetype={$_GET['housetype']}&fangshi=&dingshi={$_GET['dingshi']}&page={$_GET['page']}" {if $_GET['fangshi']==''}class="ucurent"{/if}>全部</a></span> {loop $fangshi_array $k $val} <span><a href="{APP_PATH}index.php?m=content&c=index&a=lists&catid={$catid}&paytype={$_GET['paytype']}&housetype={$_GET['housetype']}&fangshi={$k}&dingshi={$_GET['dingshi']}&page={$_GET['page']}" {if $_GET['fangshi']==$k}class="ucurent"{/if}>{$val}</a></span> {/loop} </div> <div class="udiv"><strong>支付方式</strong>: <span><a href="{APP_PATH}index.php?m=content&c=index&a=lists&catid={$catid}&paytype=&housetype={$_GET['housetype']}&fangshi={$_GET['fangshi']}&dingshi={$_GET['dingshi']}&page={$_GET['page']}" {if $_GET['paytype']==''}class="ucurent"{/if}>全部</a></span> {loop $paytype_array $k $val} <span><a href="{APP_PATH}index.php?m=content&c=index&a=lists&catid={$catid}&paytype={$k}&housetype={$_GET['housetype']}&fangshi={$_GET['fangshi']}&dingshi={$_GET['dingshi']}&page={$_GET['page']}" {if $_GET['paytype']==$k}class="ucurent"{/if}>{$val}</a></span> {/loop} </div> <div class="udiv"><strong>房屋类型</strong>: <span><a href="{APP_PATH}index.php?m=content&c=index&a=lists&catid={$catid}&paytype={$_GET['paytype']}&housetype=&fangshi={$_GET['fangshi']}&dingshi={$_GET['dingshi']}&page={$_GET['page']}" {if $_GET['housetype']==''}class="ucurent"{/if}>全部</a></span> {loop $housetype_array $k $val} <span><a href="{APP_PATH}index.php?m=content&c=index&a=lists&catid={$catid}&paytype={$_GET['paytype']}&housetype={$k}&fangshi={$_GET['fangshi']}&dingshi={$_GET['dingshi']}&page={$_GET['page']}" {if $_GET['housetype']==$k}class="ucurent"{/if}>{$val}</a></span> {/loop} </div> <div class="udiv"><strong>厅室</strong>: <span><a href="{APP_PATH}index.php?m=content&c=index&a=lists&catid={$catid}&paytype={$_GET['paytype']}&housetype={$_GET['housetype']}&fangshi={$_GET['fangshi']}&dingshi=&page={$_GET['page']}" {if $_GET['dingshi']==''}class="ucurent"{/if}>全部</a></span> {loop $dingshi_array $k $val} <span><a href="{APP_PATH}index.php?m=content&c=index&a=lists&catid={$catid}&paytype={$_GET['paytype']}&housetype={$k}&fangshi={$_GET['fangshi']}&dingshi={$k}&page={$_GET['page']}" {if $_GET['dingshi']==$k}class="ucurent"{/if}>{$val}</a></span> {/loop} </div> <br /><br /> {pc:content action="lists" cat} <ul class="photo-list picbig"> {loop $data $r} <li> <div class="img-wrap"> <a href="{$r[url]}"><img src="{thumb($r[thumb],150,112)}" width="150" height="112" alt="{$r[title]}"/></a> </div> <span style="color:{$r[style]}">{str_cut($r[title],28)}</span> </li> {/loop} </ul> <div >{$pages}</div> {/pc} </div> </div> {template "content","footer"} 转自织梦模板网,http://www.bbscms.net 相关文章: 2021-12-04 2022-02-24 2022-12-23 2023-03-18 2021-10-24 2021-05-24 2022-12-23