⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 boardprepare.jsp

📁 这是一个用JSP开发的论坛源 码。。。 按照上在的README可轻松的捅有下JSP论坛
💻 JSP
字号:
<%
long startTime=0,
     finishTime=0,
     runTime=0;
int styleID=0,
    storeStyleID=0,
    newMsgNumber=0;
String onlineView="1",
       regAccess="0",
       newMsgPop="",
       showSkin="",
       activeTime= "0000-00-00";
startTime=System.currentTimeMillis();
%>
<jsp:useBean id="forumIcon" scope="session" class="com.lyforum.forum.ForumIcon" />
<%
String onlineAdmin=forumIcon.getOnlineAdmin();
if(onlineAdmin.equals("")) {
  forumIcon.getForumIcon();

  onlineAdmin=forumIcon.getOnlineAdmin();
}
String onlineSmod=forumIcon.getOnlineSmod(),
       onlineMod=forumIcon.getOnlineMod(),
       onlineMember=forumIcon.getOnlineMember(),
       onlineRz=forumIcon.getOnlineRz(),
       onlineSelfColor=forumIcon.getOnlineSelfColor(),
       onlineGuest=forumIcon.getOnlineGuest(),
       zg_HaveNew=forumIcon.getZg_HaveNew(),
       zg_NoNew=forumIcon.getZg_NoNew(),
       kf_HaveNew=forumIcon.getKf_HaveNew(),
       kf_NoNew=forumIcon.getKf_NoNew(),
       pl_HaveNew=forumIcon.getPl_HaveNew(),
       pl_NoNew=forumIcon.getPl_NoNew(),
       bm_HaveNew=forumIcon.getBm_HaveNew(),
       bm_NoNew=forumIcon.getBm_NoNew(),
       rz_HaveNew=forumIcon.getRz_HaveNew(),
       rz_NoNew=forumIcon.getRz_NoNew(),
       jh_Pic=forumIcon.getJh_Pic(),
       lm_Pic=forumIcon.getLm_Pic(),
       newThreadLogo=forumIcon.getNewThreadLogo(),
       newPollLogo=forumIcon.getNewPollLogo(),
       newXzbLogo=forumIcon.getNewXzbLogo(),
       newReplyLogo=forumIcon.getNewReplyLogo(),
       wLogo=forumIcon.getWLogo(),
       nwLogo=forumIcon.getNwLogo(),
       help_BLogo=forumIcon.getHelp_BLogo(),
       new_BLogo=forumIcon.getNew_BLogo();
%>
<jsp:useBean id="forumStatus" scope="session" class="com.lyforum.forum.ForumStatus" />
<%
String boardname=forumStatus.getBoardName();
if(boardname.equals("")) {
  forumStatus.getForumStatus();
  boardname=forumStatus.getBoardName();
}
String title=forumStatus.getTitle(),
       version=forumStatus.getVersion(),
       boardtitle=forumStatus.getBoardTitle(),
       copyright=forumStatus.getCopyRight(),
       support=forumStatus.getSupport(),
       programmer=forumStatus.getProgrammer(),
       programemail=forumStatus.getProgramEmail(),
       homename=forumStatus.getHomeName(),
       homeurl=forumStatus.getHomeUrl(),
       status=forumStatus.getStatus(),
       maintainreason=forumStatus.getMaintainReason(),
       announcement=forumStatus.getAnnouncement(),
       boardurl=forumStatus.getBoardUrl(),
       allowUploadFileExt=forumStatus.getAddType();

if(status.equals("0")) {
  response.sendRedirect("forummaintain.jsp");
}

LogInOut loginout=new LogInOut();
try {
  loginout.checkUserStats(request,response,false);
}
catch(Exception e) {
}

loginout.getAttribute(request,response);
String cookieID=loginout.getCookieID();
String cookieName=loginout.getCookieName();
String cookieMode=loginout.getCookieMode();

if(cookieID.equals("") || cookieID.equals("0") || cookieMode.equals("") || cookieName.equals("")) {
  throw new Exception("登录用户失败,请检查用户ID!");
}

User user=new User();
//used by here and userstatus
if(cookieMode.equals("0")) {
  styleID=0;
  onlineView="1";
}
else {
  user.setUserID(Integer.parseInt(cookieID));
  user.setUserName(cookieName);
  user.getAuthorStats();
  styleID=user.getStyleID();
  onlineView=user.getOnlineView();
  //查看论坛是否有新帖
  activeTime=user.getActiveTime();
  //检查用户的短消息
  newMsgNumber=user.getNewMsgNumber();
}

%>
<jsp:useBean id="forumStyle" scope="session" class="com.lyforum.forum.ForumStyle" />
<%
String lbbody=forumStyle.getLbBody();
if(lbbody.equals("")) {
  //取styleID
  styleID=forumStyle.getStyleID(forumID,styleID);
  forumStyle.getGlobalForumStyle(styleID);
  lbbody=forumStyle.getLbBody();
}
else {
  //取styleID
  storeStyleID=forumStyle.getStoreStyleID();
  styleID=forumStyle.getStyleID(forumID,styleID);
  if(styleID!=storeStyleID) {
    forumStyle.getGlobalForumStyle(styleID);
    lbbody=forumStyle.getLbBody();
  }
}
String announcemove=forumStyle.getAnnounceMove(),
       menufontcolor=forumStyle.getMenuFontColor(),
       menubackground=forumStyle.getMenuBackGround(),
       menubackpic=forumStyle.getMenuBackPic(),
       titleborder=forumStyle.getTitleBorder(),
       font=forumStyle.getFont(),
       lastpostfontcolor=forumStyle.getLastPostFontColor(),
       fonthighlight=forumStyle.getFontHighLight(),
       posternamefont=forumStyle.getPosterNameFont(),
       posternamecolor=forumStyle.getPosterNameColor(),
       memglow=forumStyle.getMemGlow(),
       adminnamecolor=forumStyle.getAdminNameColor(),
       adminglow=forumStyle.getAdminGlow(),
       smonamecolor=forumStyle.getSmoNameColor(),
       smoglow=forumStyle.getSmoGlow(),
       teamnamecolor=forumStyle.getTeamNameColor(),
       teamglow=forumStyle.getTeamGlow(),
       banglow=forumStyle.getBanGlow(),
       fontcolormisc=forumStyle.getFontColorMisc(),
       miscbackone=forumStyle.getMiscBackOne(),
       miscbacktwo=forumStyle.getMiscBackTwo(),
       otherbackpic=forumStyle.getOtherBackPic(),
       otherbackpic1=forumStyle.getOtherBackPic1(),
       catback=forumStyle.getCatBack(),
       catbackpic=forumStyle.getCatBackPic(),
       catfontcolor=forumStyle.getCatFontColor(),
       tablebordercolor=forumStyle.getTableBorderColor(),
       tablewidth=forumStyle.getTableWidth(),
       titlecolor=forumStyle.getTitleColor(),
       titlefontcolor=forumStyle.getTitleFontColor(),
       forumcolorone=forumStyle.getForumColorOne(),
       forumcolortwo=forumStyle.getForumColorTwo(),
       forumfontcolor=forumStyle.getForumFontColor(),
       postcolorone=forumStyle.getPostColorOne(),
       postcolortwo=forumStyle.getPostColorTwo(),
       postfontcolorone=forumStyle.getPostFontColorOne(),
       postfontcolortwo=forumStyle.getPostFontColorTwo(),
       boardlogo=forumStyle.getBoardLogo();
//取用户最大不活动时间
int membergone=forumStyle.getMemberGone();
String dispview=forumStyle.getDispView();

//把超过时间没有动作的用户改成offline//更新论坛访问资料(点击次数加1)
forumStatus.setForumStats(membergone);
//取管理员的设置变量
showSkin=forumStyle.getShowSkin();
if(showSkin.equals("")) {
  forumStyle.getAdminSelected();
  showSkin=forumStyle.getShowSkin();
}
newMsgPop=forumStyle.getNewMsgPop();
if(cookieMode.equals("0"))
  onlineView=forumStyle.getOnlineView();
regAccess=forumStyle.getRegAccess();
if(regAccess.equals("1") && cookieMode.equals("0"))
  response.sendRedirect("loginout.jsp");
%>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -