home | career | drupal | java | mac | mysql | perl | php | scala | uml | unix

jforum example source code file (Upload.jsp)

This example jforum source code file (Upload.jsp) is included in the DevDaily.com "Java Source Code Warehouse" project. The intent of this project is to help you "Learn Java by Example" TM.

Java - jforum tags/keywords

jspwiki, jspwiki, logger, string, string, wikicontext, wikicontext, wikiengine, wikiengine

The jforum Upload.jsp source code

<%@ page import="org.apache.log4j.*" %>
<%@ page import="com.ecyrd.jspwiki.*" %>
<%@ page errorPage="/Error.jsp" %>
<%@ taglib uri="/WEB-INF/jspwiki.tld" prefix="wiki" %>


<%! 
    public void jspInit()
    {
        wiki = WikiEngine.getInstance( getServletConfig() );
    }
    Logger log = Logger.getLogger("JSPWiki"); 
    WikiEngine wiki;
%>

<% 
    // Create wiki context and check for authorization
    WikiContext wikiContext = wiki.createContext( request, WikiContext.UPLOAD );
    if(!wikiContext.hasAccess( response )) return;
    String pagereq = wikiContext.getName();

    // Set the content type and include the response content
    response.setContentType("text/html; charset="+wiki.getContentEncoding() );
    String contentPage = wiki.getTemplateManager().findJSP( pageContext,
                                                            wikiContext.getTemplate(),
                                                            "UploadTemplate.jsp" );
%><wiki:Include page="<%=contentPage%>" />

Other jforum examples (source code examples)

Here is a short list of links related to this jforum Upload.jsp source code file:

new blog posts

 

Other websites by Alvin Alexander:  
Life/living in Alaska (OneMansAlaska.com)
How I Sold My Business (HowISoldMyBusiness.com)

Copyright 1998-2011 Alvin Alexander, devdaily.com
All Rights Reserved.