%@page contentType="text/html;charset=utf-8" import="java.sql.*,java.util.*,jerehnet.jsp.database.*,jerehnet.jsp.util.*,java.text.SimpleDateFormat,java.util.regex.Matcher,java.util.regex.Pattern"%> <% PoolManager pool = new PoolManager(); if (pool == null) { pool = new PoolManager(); } Connection conn = null; DataManager db = new DataManager(); String flag = Common.getFormatPara(request.getParameter("flag")); String no = Common.getFormatPara(request.getParameter("no")); try { conn = pool.getConnection(); String prosql= "select count(*) as num from jrcms_products where website_no='20150623163145344' and channel_node in ( select no from jrcms_website_channel where website_no='20150623163145344' and parent_no='2015062712061219' and is_show=1 ) and is_show=1 "; ResultSet proRs=db.executeQuery(conn,prosql); String num=""; if(proRs!=null&&proRs.next()){ num=proRs.getString("num"); } String alsql=""; String anlisql="select * from jrcms_website_channel where website_no='20150623163145344' and parent_no in (select no from jrcms_website_channel where name like '%潜没电动机%' and parent_no='20150629082538135') "; ResultSet anliRs=db.executeQuery(conn,anlisql); if(anliRs!=null&&anliRs.next()){ alsql="select top 2 infor.*,ch.file_name as name from jrcms_information infor left join jrcms_website_channel ch on infor.channel_node=ch.no where infor.website_no='20150623163145344' and channel_node in (select no from jrcms_website_channel where parent_no in (select no from jrcms_website_channel where name like '%潜没电动机%' and parent_no='20150629082538135' )) order by is_top desc "; }else{ alsql="select top 2 infor.*,ch.file_name as name from jrcms_information infor left join jrcms_website_channel ch on infor.channel_node=ch.no where infor.website_no='20150623163145344' and channel_node in (select no from jrcms_website_channel where name like '%潜没电动机%' and parent_no='20150629082538135' ) order by is_top desc "; } ResultSet alRs=db.executeQuery(conn,alsql); String news="select top 4 infor.*,ch.file_name as filename from jrcms_information infor left join jrcms_website_channel ch on ch.no=infor.channel_node where infor. website_no='20150623163145344' and infor.channel_node in ( select no from jrcms_website_channel where website_no='20150623163145344' and name like '%潜没电动机%' and parent_no='20150627154536646' and is_show=1 )and infor.is_show=1 order by infor.is_recommend desc ,infor.pub_date desc"; ResultSet newsRs=db.executeQuery(conn,news); %>
<%=content%>