Solved

Alert from JSP

Posted on 2000-04-24
3
515 Views
Last Modified: 2012-08-13
I want to alert the user for form level validations in a JSP as is done in Javascript. Could somebody tell me how?
0
Comment
Question by:ssindhu
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 3

Expert Comment

by:ovidiucraciun
ID: 2743800
as far as I no, with JSP you can create dinamicaly html pages as response.
I sugest to first write your html page that makes the alertion and after that to send it to the client in order to load the page with alert code (JavaScript)
0
 

Author Comment

by:ssindhu
ID: 2743852
Thanks it works .
I created a html page with alerts using javascript(as usual) then added that to JSP.
Thanks.
0
 

Accepted Solution

by:
diegojimenez earned 100 total points
ID: 2755495
You can make all the options that you want with Html and after you can insert de java code. You must know that the java code is allways compiled in the server , and the javaScript code is compiled in the navigator.
then if you have
<%
    ----java code----
%>
<script language="JavaScript">

       function hello(){
              alert("hello");
      }
</script>
when you'll call this function the alert will be execute.
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
login jsp example 24 101
hibernate example for saving data 19 106
java imports not found 4 67
Tomcat 9 + java 8 error while trying to deploy a war file 2 839
In this post we will learn different types of Android Layout and some basics of an Android App.
In this post we will learn how to make Android Gesture Tutorial and give different functionality whenever a user Touch or Scroll android screen.
Viewers will learn about if statements in Java and their use The if statement: The condition required to create an if statement: Variations of if statements: An example using if statements:
This tutorial covers a step-by-step guide to install VisualVM launcher in eclipse.
Suggested Courses

740 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question