Characters Traveling from JSP Files to Browser Screens

This section describes how character text travels from JSP pages to Web browser screen through various steps using different technologies on different steps.

Handling non ASCII characters in JSP files correctly is not an easy task. I have seen many messages on the Web in this area reporting various frustrating situations. One main reason is that text entered in a JSP file must travel through many steps before being displayed by a browser on a screen.

The following diagram illustrates steps that characters must travel from a JSP file to a browser screen, and computing technologies that are used at different steps:

0. Key Sequences from Keyboard
      |- Text Editor
1. JSP File
      |- XML Parser
2. Java Source File
      |- Java Compiler
3. Java Class File
      |- Java Virtual Machine
4. HTML Document
      |- Web Server
5. HTTP Response
      |- Internet TCP/IP Connection
6. HTTP Response
      |- Web Browser
7. Characters on the Screen

Since all computing technologies are using ASCII encoding by default, text of ASCII characters can safely travel through those steps without any issues.

However, for non ASCII characters, we have to watch out each step carefully to make sure that characters are not damaged and decoded correctly if encoded.

Table of Contents

 About This Book

 JSP (JavaServer Pages) Overview

 Tomcat Installation on Windows Systems

 JSP Scripting Elements

 Java Servlet Introduction

 JSP Implicit Objects

 Syntax of JSP Pages and JSP Documents

 JSP Application Session

 Managing Cookies in JSP Pages

 JavaBean Objects and "useBean" Action Elements

 Managing HTTP Response Header Lines

Non-ASCII Characters Support in JSP Pages

Characters Traveling from JSP Files to Browser Screens

 Handling ASCII Characters in JSP Pages

 Presenting Non ASCII Characters in HTML Documents

 Entering Non ASCII Characters in JSP Pages

 Java Strings as non-Unicode Encoded Byte Sequences

 Java Strings as Unicode Encoded Byte Sequences

 Entering Non-ASCII Characters as Static Text

 Static HTML Text in HTML Page

 Static HTML Text in JSP Page in Standard Syntax

 Static HTML Text in JSP Page in XML Syntax

 Supporting Characters in Multiple Languages

 Performance of JSP Pages

 EL (Expression Language)

 Overview of JSTL (JSP Standard Tag Libraries)

 JSTL Core Library

 JSP Custom Tags

 JSP Java Tag Interface

 Custom Tag Attributes

 Multiple Tags Working Together

 File Upload Test Application

 Using Tomcat on CentOS Systems

 Using Tomcat on macOS Systems

 Connecting to SQL Server from Servlet

 Developing Web Applications with Servlet

 Archived Tutorials


 Full Version in PDF/EPUB