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

📄 _index__jsp.java

📁 JSP聊天系统
💻 JAVA
📖 第 1 页 / 共 4 页
字号:
      pageContext.write(_jsp_string40, 0, _jsp_string40.length);
      out.print(( logoutButtonURL ));
      pageContext.write(_jsp_string34, 0, _jsp_string34.length);
      out.print(( logoutButtonImgAltText ));
      pageContext.write(_jsp_string16, 0, _jsp_string16.length);
      out.print(( logoutButtonText ));
      pageContext.write(_jsp_string42, 0, _jsp_string42.length);
      	} 
      pageContext.write(_jsp_string43, 0, _jsp_string43.length);
      	} 
      pageContext.write(_jsp_string26, 0, _jsp_string26.length);
      	////////////////////////////////////////////////////
	// customize which forums are displayed on this page
	
	// There are two ways to decide which forums get diplayed to the user
	//
	//	1.	Display a list of all forums the current user has permission to
	//		view. For instance, if there are 4 forums in the system and
	//		a "guest" has authorization to view 2 of them, then just those
	//		two forums will be displayed. This works the same way for 
	//		registered users -- they'll only see the forums they have 
	//		access to.
	//		
	//	2.	Specify by name which forums to display. Again, if there are
	//		4 forums in the system and you specify all forums by name and
	//		the skin user has access to only 2 of them, then only 2 forums
	//		will be displayed
	
	// Set the following boolean variable to "false" to display a list
	// of forums in the system (case 1) or set it to "true" to specify
	// a list of forums by name (case 2)
	
	boolean loadForumsByName = false;
	
	// If you choose to load forums by name, specify the names by
	// adding them to the following list of forum names:
	
	ArrayList forumNames = new ArrayList(0);
	if( loadForumsByName ) {
		forumNames.add( "First Forum" );
		forumNames.add( "Another Forum" );
	}

      pageContext.write(_jsp_string44, 0, _jsp_string44.length);
      	/////////////////////
	// check for messages
	
	// we might come to this page from another page and that page might
	// pass us a message. If so, grab it and display it (also remove it from persistence)
	String message = SkinUtils.retrieve(request,response,"message",true);
	if( message != null ) {

      pageContext.write(_jsp_string45, 0, _jsp_string45.length);
      out.print(( message ));
      pageContext.write(_jsp_string46, 0, _jsp_string46.length);
      	} 
      pageContext.write(_jsp_string47, 0, _jsp_string47.length);
      	// print out a greeting to a registered user.
	
	if( !user.isAnonymous() ) { 
      pageContext.write(_jsp_string48, 0, _jsp_string48.length);
      out.print(( user.getName() ));
      pageContext.write(_jsp_string49, 0, _jsp_string49.length);
      out.print(( user.getName() ));
      pageContext.write(_jsp_string50, 0, _jsp_string50.length);
      	} 
      pageContext.write(_jsp_string51, 0, _jsp_string51.length);
      out.print(( forumTableBgcolor ));
      pageContext.write(_jsp_string52, 0, _jsp_string52.length);
      out.print(( forumTableBgcolor ));
      pageContext.write(_jsp_string53, 0, _jsp_string53.length);
      out.print(( forumTableHeaderFgcolor ));
      pageContext.write(_jsp_string54, 0, _jsp_string54.length);
      	//////////
	// Note:
	
	// the following java code should not be modified -- changing html is ok.
	
	// The iterator we use to loop through forums
	Iterator forumIterator;
	if( loadForumsByName ) {
		forumIterator = forumNames.iterator();
	}
	else {
		forumIterator = forumFactory.forums();
	}

      pageContext.write(_jsp_string1, 0, _jsp_string1.length);
      	/////////////////////
	// loop through forums, display forum info:
	if( !forumIterator.hasNext() ) {

      pageContext.write(_jsp_string55, 0, _jsp_string55.length);
      out.print(( forumTableFgcolor ));
      pageContext.write(_jsp_string56, 0, _jsp_string56.length);
      	}
	boolean forumLoaded = false;
	while( forumIterator.hasNext() ) {
		Forum forum;
		// since loading a forum could throw an unauthorized exception, we 
		// should catch it so we can skip this forum and try to load another
		// forum
		try {
			if( loadForumsByName ) {
				forum = forumFactory.getForum( (String)forumIterator.next() );
			}
			else {
				forum = (Forum)forumIterator.next();
			}
			forumLoaded = true;
			int forumID = forum.getID();
			String forumName = forum.getName();
			String forumDescription = forum.getDescription();
			int threadCount = forum.getThreadCount();
			int messageCount = forum.getMessageCount();
			Date creationDate = forum.getCreationDate();
			Date modifiedDate = forum.getModifiedDate();
			boolean wasModified = (userLastVisitedTime < modifiedDate.getTime());

      pageContext.write(_jsp_string57, 0, _jsp_string57.length);
      out.print(( forumTableFgcolor ));
      pageContext.write(_jsp_string58, 0, _jsp_string58.length);
      out.print(( (wasModified)?"bang":"blank" ));
      pageContext.write(_jsp_string59, 0, _jsp_string59.length);
      out.print(( forumID ));
      pageContext.write(_jsp_string60, 0, _jsp_string60.length);
      out.print(( forumName ));
      pageContext.write(_jsp_string61, 0, _jsp_string61.length);
      out.print(( threadCount ));
      pageContext.write(_jsp_string62, 0, _jsp_string62.length);
      out.print(( messageCount ));
      pageContext.write(_jsp_string63, 0, _jsp_string63.length);
      out.print(( (forumDescription!=null)?forumDescription:"&nbsp;" ));
      pageContext.write(_jsp_string64, 0, _jsp_string64.length);
      out.print(( SkinUtils.dateToText(modifiedDate) ));
      pageContext.write(_jsp_string65, 0, _jsp_string65.length);
      		} catch( UnauthorizedException ignored ) {
		}
	}
	
	// if no forums were successfully loaded, print out a "error, no 
	// permissions" message
	if( !forumLoaded ) {

      pageContext.write(_jsp_string55, 0, _jsp_string55.length);
      out.print(( forumTableFgcolor ));
      pageContext.write(_jsp_string66, 0, _jsp_string66.length);
      	}

      pageContext.write(_jsp_string67, 0, _jsp_string67.length);
      	/////////////////////
	// page footer 

      pageContext.write(_jsp_string0, 0, _jsp_string0.length);
      pageContext.write(_jsp_string0, 0, _jsp_string0.length);
      
/**
 *	$RCSfile: footer.jsp,v $
 *	$Revision: 1.3.2.1 $
 *	$Date: 2001/01/21 21:30:25 $
 */

      pageContext.write(_jsp_string0, 0, _jsp_string0.length);
      pageContext.write(_jsp_string68, 0, _jsp_string68.length);
    } catch (java.lang.Throwable _jsp_e) {
      pageContext.handlePageException(_jsp_e);
    } finally {
      JspFactory.getDefaultFactory().releasePageContext(pageContext);
    }
  }

  private com.caucho.java.LineMap _caucho_line_map;
  private java.util.ArrayList _caucho_depends = new java.util.ArrayList();

  public boolean _caucho_isModified()
  {
    if (_caucho_isDead)
      return true;
    if (com.caucho.util.CauchoSystem.getVersionId() != 2057024146)
      return true;
    for (int i = _caucho_depends.size() - 1; i >= 0; i--) {
      com.caucho.vfs.Depend depend;
      depend = (com.caucho.vfs.Depend) _caucho_depends.get(i);
      if (depend.isModified())
        return true;
    }
    return false;
  }

  public long _caucho_lastModified()
  {
    return 0;
  }

  public com.caucho.java.LineMap _caucho_getLineMap()
  {
    return _caucho_line_map;
  }

  public void destroy()
  {
      _caucho_isDead = true;
      super.destroy();
  }

  public void init(com.caucho.java.LineMap lineMap,
                   com.caucho.vfs.Path appDir)
    throws javax.servlet.ServletException
  {
    com.caucho.vfs.Path resinHome = com.caucho.util.CauchoSystem.getResinHome();
    com.caucho.vfs.MergePath mergePath = new com.caucho.vfs.MergePath();
    mergePath.addMergePath(appDir);
    mergePath.addMergePath(resinHome);
    mergePath.addClassPath(getClass().getClassLoader());
    _caucho_line_map = new com.caucho.java.LineMap("_index__jsp.java", "/forum/footer.jsp");
    _caucho_line_map.add("/forum/index.jsp", 15, 1);
    _caucho_line_map.add("/forum/header.jsp", 20, 1);
    _caucho_line_map.add("/forum/breadcrumb.jsp", 20, 1);
    _caucho_line_map.add("/forum/toolbar.jsp", 1, 1);
    _caucho_line_map.add("/forum/footer.jsp", 9, 1);
    _caucho_line_map.add("/forum/index.jsp", 18, 17);
    _caucho_line_map.add("/forum/header.jsp", 13, 25);
    _caucho_line_map.add("/forum/breadcrumb.jsp", 11, 32);
    _caucho_line_map.add("/forum/toolbar.jsp", 10, 41);
    _caucho_line_map.add("/forum/index.jsp", 2, 66);
    _caucho_line_map.add(10, 75);
    _caucho_line_map.add(15, 76);
    _caucho_line_map.add(18, 77);
    _caucho_line_map.add(27, 78);
    _caucho_line_map.add(69, 121);
    _caucho_line_map.add("/forum/header.jsp", 2, 122);
    _caucho_line_map.add(13, 131);
    _caucho_line_map.add(20, 132);
    _caucho_line_map.add(116, 134);
    _caucho_line_map.add(135, 154);
    _caucho_line_map.add(136, 156);
    _caucho_line_map.add(136, 158);
    _caucho_line_map.add(136, 160);
    _caucho_line_map.add(136, 162);
    _caucho_line_map.add(136, 164);
    _caucho_line_map.add(163, 166);
    _caucho_line_map.add("D:\\resin-2.1.4\\doc\\forum\\index.jsp", 72, 168);
    _caucho_line_map.add(81, 178);
    _caucho_line_map.add("/forum/breadcrumb.jsp", 2, 179);
    _caucho_line_map.add(9, 187);
    _caucho_line_map.add(11, 188);
    _caucho_line_map.add(20, 189);
    _caucho_line_map.add(22, 192);
    _caucho_line_map.add(33, 204);
    _caucho_line_map.add(33, 206);
    _caucho_line_map.add(39, 213);
    _caucho_line_map.add(57, 232);
    _caucho_line_map.add(58, 234);

⌨️ 快捷键说明

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