查看文件: shopmap.php
大小: 5.78 KB
类型: application/octet-stream
<?php require_once('../Connections/BE2.php'); ?> <? $co1=isset($_GET['menu'])?$_GET['menu']:''; if($co1<>''){ mysql_select_db($database_BE2, $BE2); // AND b.ycity='不分區' OR b.ycity='%s' $query_Rt2 = sprintf("SELECT * FROM video_master as a left join youvideo as b on a.vid=b.ykid AND b.yflag='Y' where a.vflag='Y' AND a.vkid like '%s' AND a.vzone like '%s' order by a.vindex,a.vid,b.yindex" ,'%購物網%', '%'.$co1.'%') ; $Rt2 = mysql_query($query_Rt2, $BE2) or die(mysql_error()); $row_Rt2 = mysql_fetch_assoc($Rt2); $totalRows_Rt2 = mysql_num_rows($Rt2); mysql_select_db($database_BE2, $BE2); $query_Rt3 = sprintf("SELECT a.*,b.company_title,b.company_pic,b.mid FROM company_kinds as a left join company as b on b.co_tb1=1 AND a.kid=b.co_tb2 AND b.company_title<>'' AND b.co_tb3='%s' WHERE a.kflag='Y' order by a.kindex",$co1); //b.company_kind>1 AND $Rt3 = mysql_query($query_Rt3, $BE2) or die(mysql_error()); $row_Rt3 = mysql_fetch_assoc($Rt3); $totalRows_Rt3 = mysql_num_rows($Rt3); // if ( $_SERVER['REMOTE_ADDR']=='220.130.43.118'){ echo $query_Rt2. '<p>'.$query_Rt3 ; } } $title="";//$row_Rt3['company_title']; $i=0; ?> <style> #divx{ // border: 1px solid black; width: 100%; margin-bottom: 12px; overflow-x: auto; //hidden scroll visible auto } .divimg{ position: relative; width: 130px; height: 108px; } /*div1下面 包含着1个图片和1段文字*/ #div1{ position: relative;/*相对定位*/ width: 138px; height: 108px; } /*图片部分的设置*/ #img1{ /*position: static;默认定位,可以省略*/ width: 100%; height: 100%; } /*文字的设置*/ #span1{ position: absolute;/*绝对定位*/ background-color:#333; width: 95%; bottom: 0px;/*离底下0像素*/ left: 0px;/*离左边0像素*/ text-align: center; font-size: 16px; font-weight:bold; color: white; filter: alpha(opacity=50); /* internet explorer */ -khtml-opacity: 0.5; /* khtml, old safari */ -moz-opacity: 0.5; /* mozilla, netscape */ opacity: 0.5; /* fx, safari, opera */ } </style> <div class="clearfix"> </div> <div class="container" style="margin-top:20"> <div class="row"> <? if($co1==''){ include "../city_link.php"; } else {?> <div class="col-12 align-self-center"> <div id="divx"> <table cellspacing="1" > <? // R2 $i=0; $vid=''; do { if($vid<>$row_Rt2['vid']){ $vid=$row_Rt2['vid']; if($i>0){ echo '</tr>'; } $logo_image=sprintf("%04d",$row_Rt2['vid']).$row_Rt2['vimg'].'.png'; ?> <tr align="center" valign="middle"> <td> <? $a1=''; $a2=''; //if($row_Rt2['vlink']<>''){ $a1='<a href="'.$row_Rt2['vlink'].'">'; $a2= '</a>' ;} $a1='<a href="/discover/'.$row_Rt2['vdoc'].'.html">'; $a2= '</a>' ; echo $a1;?><img name="" src="/video_img/logo/<?= $logo_image; ?>" title="<?= $row_Rt2['vdoc']; ?>"/><?= $a2;?></td> <? $i++; } if($row_Rt2['ylink']<>''){ ?> <td width="150"><div id="div1"> <? if($row_Rt2['video']=='Y'){?> <div class="embed-responsive embed-responsive-16by9" style=" margin-right:15px; margin-top:20px"> <iframe class= "embed-responsive-item" width="90%" src= "https://www.youtube.com/embed/<?= $row_Rt2['ylink'] ?>" allowfullscreen> </iframe> </div> <span style="font-size:0.875em"> <?= mb_substr($row_Rt2['ydoc'], 0, 5, "UTF-8") ; ?></span> <? } else{?> <a href="<?= $row_Rt2['ylink'] ?>"><img src="/video_img/logo/<?= $row_Rt2['yimage'];?>" title="<?= $row_Rt2['vdoc']?>" width="130" height="108" /></a> <? } ?> </div> </td> <? } } while ($row_Rt2 = mysql_fetch_assoc($Rt2)); mysql_free_result($Rt2); ?> </table> </div> <? $title=""; $i=0; ?> <div id="divx"> <table> <? $title=""; $i=0; do { ?> <? if($title<>$row_Rt3['kid']){ $title=$row_Rt3['kid']; if($i>0){ echo '</tr>'; } ?> <tr> <td> <? if($row_Rt3['kimg']==''){ $logo_image='lbg_'.sprintf("%07d",$row_Rt3['kid']).'.png'; }else{ $logo_image=sprintf("%04d",$row_Rt3['kid']).$row_Rt3['kimg'].'.png'; } ?> <img name="" src="images/<?= $logo_image ?>" title="<?= $row_Rt3['company_title'].$row_Rt3['kdoc']?>" /></td> <? $i++; } if($row_Rt3['company_title']<>''){ $file_ext=$row_Rt3['company_pic']; if($file_ext=='png'){ $f='/www2/skybni/shopmap/images/logo_'.$row_Rt3['mid'].'.png'; if(filesize($f)==361) {$file_ext='jpg';} } ?> <td><a href="/shop/<?= $row_Rt3['company_title']?>.html"><img name="" src="images/logo_<?= $row_Rt3['mid'].'.'.$file_ext;?>" title="<?= $row_Rt3['company_title'].$row_Rt3['kdoc']?>" width="130" height="108" /></a></td> <? }?> <? } while ($row_Rt3 = mysql_fetch_assoc($Rt3)); mysql_free_result($Rt3); ?> </table> </div> </div> <? }?> </div> </div> <script type="text/javascript"> function gotourl(){ window.location.href='/'; } function Selectstreet() { var county= "<?= $county ?>"; var district = $("#district").val(); $.ajax({ type: 'POST', url: 'SelectcityApi.php', data: { 'county': county,'district':district }, success: function (data) { var $street = $('#street'); $street.empty(); $("select#street").html(data); } }); } </script>
保存
取消
返回文件列表