• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Paul Clapham
  • Ron McLeod
  • paul wheaton
  • Devaka Cooray
Sheriffs:
  • Jeanne Boyarsky
  • Tim Cooke
  • Liutauras Vilda
Saloon Keepers:
  • Tim Moores
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
  • Piet Souris
Bartenders:
  • salvin francis
  • Mikalai Zaikin
  • Himai Minh

problem in using Ajax calls

 
Ranch Hand
Posts: 32
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
<table border="0" class="body_block">
<tr>
<td >
<table >
<tr><td >Geographical Area Code</td>
   <td > Geographical Area</td></tr>
<bean:define id="geographical" name="geographicalDetails" scope="request" type="java.util.HashMap" />
<logic:iterate id="forums" name="geographical">
<tr></tr>
<tr><td >','<bean:write name="forums" property="value"/>');"><bean:write name="forums" property="key"/></td>
<td ><bean:write name="forums" property="value"/></td></tr>
</logic:iterate>
</table>
</td>

<td > </td>
<td >
<div id="geograhicalDiv">
<table border="0" >
<tr>




<td >

<strong>Geographical Area Sales</strong>




</td>
</tr>
<tr>

<td >
<html:errors/>
<form name="Form1" method="post" action="uploadDetails.do" ID="Form1">
<table border="0" class="tabular_data">



</table>

<table border="0" >
<tr>
<td>
<div align="center">

          
<input type="submit" name="Submit" class="bButton" value="Upload" onClick="return validationCheck();">   
<input type="button" name="button1" class="bButton" value="Back" onclick="onClickBack();">
</div>
</td>
</tr>
<tr><td>





</td></tr>
</table>
<%
String count=(String)request.getAttribute("successCount");
if(count!=null){
%>
   The Total Updated Records are:<%=count %>
<%
}
%>
</form>

</td>
</tr>
<tr>
<td >Upload Guidelines :

     * File Format for Prepaid SIM - File must have following mandatory columns in same order.

               SAPInvoiceNumber,SAPInvoiceDate,Dist SAP Code,SAP Item Code,SIM Serial number,MSISDN

     * File Format for Recharge Coupon - File must have following mandatory columns in same order.

              SAPInvoiceNumber,SAP InvoiceDate,Dist SAP Code,SAP Item Code,Series From,Series To

     * Date format should be DD-MMM-YYYY i.e. 12-JUL-2009

     * File must be saved as .CSV which is comma separated file.

     * File should not have any blank record.

<blockquote> </blockquote></td>
</tr>
<!--<tr>

<!--<td height="10"> </td>
</tr>-->
</table>
</div>
</td>
</tr>
</table>


function getDetails(key,value){
alert("key---------->"+key);
alert("value---------->"+value);
document.getElementById("hiddenKey").value=key;
document.getElementById("hiddenValue").value=value;
var url = 'getGeographicalDetails.action?&ts='+new Date();
alert('After groupId ----------'+document.getElementById("hiddenKey").value);
if (window.XMLHttpRequest) {
alert("from if");
req = new XMLHttpRequest();
} else if (window.ActiveXObject) {
req = new ActiveXObject("Microsoft.XMLHTTP");
alert("from else if");
}
alert("the URL------------->"+url);
req.onreadystatechange = displaySuccess;
req.open("GET",url, true);
req.send(null);

}

function displaySuccess()
{
alert("From displaySuccess--------"+req.readyState);
if (req.readyState == 4)
{
alert("From displaySuccess--req.status------"+req.status);
if (req.status == 200) {
document.getElementById("geograhicalDiv").innerHTML=req.responseText;
var svalue=document.getElementById("geograhicalDiv").innerHTML=req.responseText;
alert("The value is ---"+ svalue);
}
}
}
 
Sheriff
Posts: 67529
173
Mac Mac OS X IntelliJ IDE jQuery TypeScript Java iOS
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
And?
 
Author
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
And PLEASE UseCodeTags.
 
Can you hear that? That's my theme music. I don't know where it comes from. Check under this tiny ad:
Thread Boost feature
https://coderanch.com/t/674455/Thread-Boost-feature
reply
    Bookmark Topic Watch Topic
  • New Topic