advertisement
javaboutique
Search Tips
Articles  |   Tutorials  |   Reviews  |   Tools  |   by Category  |   by Date  |   by Name  |   Submit  |   Source  |   Forums  |  
javaboutique
Browse DevX


Partners & Affiliates











advertisement

Reviews : Java Books : Professional JSP Site Design : Chapter 12:



Title: Professional JSP Site Design
ISBN: 1861005512
Price: $ 59.99
£ 43.99
C$ 89.95
© Wrox Press, Ltd.

Content Management

Eye candy brings them in, but content brings them back, especially if that content is kept up-to-date and topical. Armed with a good tool, we can convert the effort needed to keep a site current from an everyday struggle into a daily pleasure. This chapter steps through a case study that develops an article management system for a news site, or any site that posts articles on a regular basis.

We'll build on this example throughout this chapter and the next two. In this chapter, the application is a simple news posting utility. Then we will use it to provide the articles as subscription content to other sites. Finally, we will enhance the search capabilities to make the articles easier to find.

We will be building the application using the Struts Framework, introduced in Chapter 2. If your own applications are built with Struts, our news poster could be plugged in as a JAR library, and the control- flow mappings copied into your own Struts configuration file. The articles case study is a simple database application that demonstrates best practices you can use in other Struts projects.

Before we get started, let's discuss why a news poster is a good choice for a content management case study.

Managing Timely Content

Most of the work in content management today revolves around:

  • Separating content from the presentation layer
  • Making updated content available wherever it is needed
  • Organizing and searching content

The conventional approach for separating content from presentation is to use XML to store the content, which is then formatted at run time using a stylesheet. See Chapter 12 of Professional JSP 2nd Edition from Wrox Press (ISBN 1-861004-95-8) for more about using XML with JSP pages.

However, using XML and stylesheets this way is still a developing technology. Initiatives like Apache Cocoon (http://xml.apache.org/cocoon/) and Apache Slide (http://jakarta.apache.org/slide/) are going to have a lot to offer us in the near future, but are not quite ready for everyday use in a production site. For most working web sites, the last two points, keeping content update fresh and making it easy to find, are the issues that need to be addressed today.

HTML is a capable format for creating static pages, and with JSP, dynamic pages can be created without much effort. However, a problem many web sites still have is that continually adding new content to the site requires knowledgeable personnel who can be trusted to add a new page without disrupting the others. Adding a new page often means updating another index page so that the visitors can find it. So, the person adding the page has to know how to do that too, and be trusted to do it correctly.

Where this tends to happen most often is with articles that are posted to a site on a regular basis. These may be news articles, a column, or just "what's new" snippets. Generally, the latest posting replaces the previous posting, which is relegated to an archive.

A way to streamline posting material like this is to use a news posting utility. This is the most common approach to content management today. News posters are running many popular sites, like SlashDot (http://slashdot.org/) and NewsForge (http://www.newsforge.com/). See Chapter 14 for more about these sites, where we cover another popular approach to content management – portals. While there is no shortage of news posting applications for other platforms like PHP, there is very little available for Java web applications. So, let's fill that gap with a news posting application of our own.

Articles

First, to give us a place to start, let's set out a simple workflow for our base application, and highlight some technical requirements the application must meet.

Workflow

A workflow is the flow or progress of work done by a company, industry, department, or person. Sometimes an entire workflow can be represented within an application. More often, an application represents only part of a greater workflow. A point-of-sale application may record the sale and order inventory, but it doesn't put the merchandise into the bag and hand it to the customer.

Our news poster is part of a greater workflow that would include identifying articles to write, writing the articles, and perhaps approving them for publication. For now, let's look at that portion of the overall workflow that must be handled by our example application for it to be useful:

  • Contributors log in to the application
  • Contributors complete a web form with the article's title, author, and content as a text paragraph or HTML
  • Contributors may edit or delete their own articles, and the articles of other contributors
  • Visitors may list current articles by date entered, or search for specific articles by title, author, or content

How to Add Java Applets to Your Site

New on the Java Boutique:

New Review:

Time Management Made Easy with the Quartz Enterprise Job Scheduler
Why not just use the Java timer API? This open source scheduling API boasts simplicity, ease-of-integration, a well-rounded feature set, and it's free!

New Applet:

Reverse Complement
Reverse Complement is a simple applet that converts DNA or RNA sequences into three useful formats.

Elsewhere on internet.com:

WebDeveloper Java
Lots of Java information on webdeveloper.com

WDVL Java
Thorough Java resource at the Web Developer's Virtual Library.

ScriptSearch Java
Hundreds of free Java code files to download.

jGuru: Your View of the Java Universe
Customizable portal with online training, FAQs, regular news updates, and tutorials.

 Internet.com eBook Library
 IBM Software Construction Toolbox
 Microsoft RIA Development Center
 Destination .NET
XML error: not well-formed (invalid token) at line 38
advertisement
Receive Articles via our XML/RSS feed
Receive Articles via our XML/RSS feed

JavaBytes
Internet Cyclone
This powerful, easy-to-use, internet optimizer is for Windows 95, 98, ME, NT, 2000 and XP. It's designed to automatically optimize your Windows settings, boosting your Internet connection up to 200%.

Mozilla's Ubquity Mashup: For The Masses?
iPhone Users Just Want to Have Fun
Oops! I Fixed the Linux Kernel
Jim Zemlin: The New Center of Linux Gravity
Microsoft's Novell Investment Tops $340M
Fedora 10 Takes Shape
IBM Gives a Mobile Voice to Developers
Inadequate Tools Send Software Down the Drain
USB 3.0 One Step Closer to Reality
Would-Be Linux Contributors May Get a Leg Up

Develop a Mobile RSS Feed the Easy Way
State of the Semantic Web: Know Where to Look
A 3D Exploration of the HTML Canvas Element
Setting Up and Running Subversion and Tortoise SVN with Visual Studio and .NET
Java/JRuby Developers, Say Open 'Sesame' to the Semantic Web
Interpreting Images with MRDS Services
DevXtra Editors' Blog: Executives Avoiding Cloud Computing in Droves
Q&A with James Reinders on the Intel Parallel Studio Beta Program
The Pros and Cons of Outsourcing Enterprise Emails
Hosting Options: Shared or Dedicated Server

Advertising Info  |   Member Services  |   Contact Us  |   Help  |   Feedback  |   Site Map  |   Network Map  |   About



JupiterOnlineMedia

internet.comearthweb.comDevx.commediabistro.comGraphics.com

Search:

Jupitermedia Corporation has two divisions: Jupiterimages and JupiterOnlineMedia

Jupitermedia Corporate Info


Legal Notices, Licensing, Reprints, & Permissions, Privacy Policy.

Advertise | Newsletters | Tech Jobs | Shopping | E-mail Offers