<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%-- jstl1.2--%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>

<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt"%> 

<%@ page isELIgnored="false" %> 
<%@page  import="miincms.dao.CmsArticleCat" %>

<%@page  import="miincms.view.pages.IndexPage
         ,miincms.view.pages.base.CmsBasePage" %>

<% 
//获取页面对象
IndexPage index=new IndexPage(request,response,out);
index.loadPageDate();
                %>
<!DOCTYPE html>
<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <title>JSP Page</title>
    </head>
    <body>
        
        
           <jsp:include page="./include/navBar.jsp" ></jsp:include>
        
      
    
        <jsp:include page="./include/cat_list_cms.jsp" ></jsp:include>
        
        
        
     
              
                <!-- #webComponent.start.newArticleList -->
                <%
                // #webComponent.start.newArticleList
                miincms.view.pages.uiCompont.NewArticleListComponent newArticleList
                        =new miincms.view.pages.uiCompont.NewArticleListComponent (
                            request, response, out
                         );
                //返回记录数
                int max=10;
                //标题长度，字符
                int titleLen=50;
                newArticleList.init(max,titleLen);
                    %>
                <div id="webComponent">
                    
                    <p id="webComponent_id_232352" class="webComponent_edit" style="display:block;">
                                                
                    </p>
                    
                    <div class="webComponent_content">
                        <p>最新</p>
                        <p>
                             <ul>
                                 <c:if test="${NewArticleListCms!=null}" >  
                            <c:forEach items="${NewArticleListCms}" var="article">
                                <li>
                             <a href="./article.jsp?aid=<c:out value="${article.aid}"/>" >
                                    <c:out value="${article.title}"></c:out>
                               </a></li>                                
                            </c:forEach>
                               </c:if> 
                             </ul>
                        </p>
                    </div>
                    
                </div>
                 <!-- webComponent.end.newArticleList -->
                 
                 
                 
                  <!-- #webComponent.start.cmdArticleList -->
                <%
                // #webComponent.start.cmdArticleList
                miincms.view.pages.uiCompont.CmdArticleListComponent cmdArticleList
                        =new miincms.view.pages.uiCompont.CmdArticleListComponent (
                            request, response, out
                         );
                   //返回记录数
                int max_cmd=10;
                //标题长度，字符
                int titleLen_cmd=50;
                cmdArticleList.init(max_cmd,titleLen_cmd);
               
                    %>
                <div id="webComponent">
                    
                    <p id="webComponent_id_232352" class="webComponent_edit" style="display:block;">
                                                
                    </p>
                    
                    <div class="webComponent_content">
                         <p>推荐</p>
                        <p>
                             <ul>
                                 <c:if test="${CmdArticleListCms!=null}">    
                                     <c:forEach items="${CmdArticleListCms}" var="article">
                                      <li>
                                  <a href="./article.jsp?aid=<c:out value="${article.aid}"/>" >
                                    <c:out value="${article.title}"></c:out>
                                     </a></li>                                
                                </c:forEach>
                                 </c:if>
                             </ul>
                        </p>
                    </div>
                    
                </div>
                 <!-- webComponent.end.cmdArticleList -->
                 
                  <!-- #webComponent.start.hotArticleList -->
                <%
                // #webComponent.start.newArticleList
                miincms.view.pages.uiCompont.HotArticleListComponent hotArticleList
                        =new miincms.view.pages.uiCompont.HotArticleListComponent (
                           request, response, out
                         );
                     //返回记录数
                int max_hot=10;
                //标题长度，字符
                int titleLen_hot=50;
                hotArticleList.init(max_hot,titleLen_hot);
                
                    %>
                <div id="webComponent">
                    
                    <p id="webComponent_id_232352" class="webComponent_edit" style="display:block;">
                                                
                    </p>
                    
                    <div class="webComponent_content">
                        <p>热点</p>
                        <p>
                             <ul>
                                  <c:if test="${HotArticleListCms!=null}">  
                                        <c:forEach items="${HotArticleListCms}" var="article">
                                        <li>
                                          <a href="./article.jsp?aid=<c:out value="${article.aid}"/>" >
                                    <c:out value="${article.title}"></c:out>
                                          </a></li>                                
                                        </c:forEach>
                                    </c:if>
                                  </ul>
                        </p>
                    </div>
                    
                </div>
                 <!-- webComponent.end.hotArticleList -->
    </body>
</html>
