With Rich's help...I have the following files. But nothing seems to be
working. Please advise if I'm missing anything.

1. test.jsp
2. calculate.jsp - dummy jsp
3. review.jsp - dummy jsp
4. jquery-1.3.2.js 
5. jquery.blockUI.js
6. And two graphics. 

When I run the test.jsp page http://localhost/testProject/test.jsp and click
on the calculate button, it changes the URL but does nothing. This is the
changed URL
http://localhost/vendorManagement/test.jsp?txt=1223&Submit.x=50&Submit.y=13

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3c.org/TR/1999/REC-html401-19991224/loose.dtd";> 
<HTML> 
<HEAD> 
<TITLE>Processing</TITLE> 
<META http-equiv=content-type content="text/html; charset=UTF-8"> 
<script type="text/javascript" src="jquery-1.3.2.js"></script> 
<script type="text/javascript" src="jquery.blockUI.js"></script> 
<SCRIPT type=text/javascript> 

$(document).ready( function() { 

/* Block the UI... */ 
$('#submit').click(function() { 
$.blockUI({ message: $('#processing') }); 

/* do the AJAX call and processing here... */ 
var txtval = $("#txt").val(); 
$.post("calculate.jsp", { txt: txtval }, 
function(data){ 
if(data.length >0) { 
window.location.href("review.jsp"); 
} 
}); 
}); 
// unblock UI when ajax request completes 
complete: function(x,y) { 
$.unblockUI(); 
} 
}); 

</SCRIPT> 
<STYLE type=text/css> 
body { 
background: #FFF; 
font: normal 12px Arial, Helvetica, sans-serif; 
padding: 0; 
margin:0; 
} 

#processing { 
padding:0; 
margin:0; 
} 
.BoxTitle { 
border-bottom:#ccc 1px solid; 
font-family: "Lucida Grande", Helvetica, Arial, sans-serif; 
font-size: 18px; 
font-weight:bold; 
color: #005b9c; 
line-height: 120%; 
margin-bottom:5px; 
padding:2px 0; 
} 
</STYLE> 
</HEAD> 
<BODY> 
<P> 

<table width="100%" border="0" cellspacing="0" cellpadding="0"> 
<tr> 
<td align="center"><br> 
<br> 
<br> 


<br> 
<form> 
Enter a value: 
<input type="text" id="txt" name="txt"><br> 
<br> 
<input id="submit" src="img/calculate.gif" type="image" name="Submit"
value="Calculate" /> 
</form> 

</td></tr> 
</table> 

<div id=processing style="display:none;"> 
<div style="text-align:center;padding:15px;font: normal 13px Arial,
Helvetica, sans-serif;color:#cc6633;font-weight:bold;width:350px"> 
<div class="BoxTitle" style="text-align:center;">Calculation in
Progress.</div> 
img/ajaxloader.gif  
<P>Please Stand By......</P> 
</div> 
</div> 

</BODY> 
</HTML> 
-- 
View this message in context: 
http://old.nabble.com/Block-UI-question-tp26174291s27240p26203460.html
Sent from the jQuery General Discussion mailing list archive at Nabble.com.

Reply via email to