Saturday, 10 January 2026

Simple JSP Hello World Program

 JSP formerly called Java Server Pages and later community renamed it to Jakarta Server Pages is used to generate dynamic web pages that appear in the web browser. It holds the View layer of the MVC(Model - View - Controller) architecture and is an alternative to Servlet and Thymeleaf. Below are simple beginner friendly steps for using the JSP.

1. First step requires opening the Eclipse Enterprise IDE if it is not installed try following this simple tutorial for installing the Eclipse Enterprise IDE in Linux System.











2. Creating Dynamic Web Project













3. Next it requires naming jsp_hello_world as the project name and then requires clicking the finish button



























4.
 Next it requires navigating to the webapp folder in the project explorer














5. Next it requires creating a new JSP file in the webapp folder














6. Next it requires naming the JSP file and clicking the Finish button
















7. Next the autogenerated boilerplate code output can be seen as in the below image









8. Next it requires editing the title and adding the heading "Hello world" as in below image









9. Next it requires right clicking the JSP file content and running the simple app on the Apache Tomcat server














10. Next it requires selecting existing server or deploying new server and hitting Finish button
















11. Next a browser pop up appear at the top to open the output in the Browser(in our case its Chromium)











12. Finally a JSP hello world output appearance can be seen in the browser



No comments:

Post a Comment