topical media & game development

talk show tell print

professional-ajax-02-Hidden-IFrame-Examples-HiddenIFrameExample1.htm / htm

  <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
      <title>Hidden IFrame Example 1</title>
      <script type="text/javascript">
          function requestCustomerInfo() {
              var sId = document.getElementById("txtCustomerId").value;
              top.frames["hiddenFrame"].location = "GetCustomerData.php?id=" + sId;
          function displayCustomerInfo(sText) {
              var divCustomerInfo = document.getElementById("divCustomerInfo");
              divCustomerInfo.innerHTML = sText;
      <p>Enter customer ID number to retrieve information:</p>
      <p>Customer ID: <input type="text" id="txtCustomerId" value="" /></p>
      <p><input type="button" value="Get Customer Info" onclick="requestCustomerInfo()" /></p>
      <div id="divCustomerInfo"></div>
      <iframe src="about:blank" name="hiddenFrame" width="0" height="0" frameborder="0"></iframe>

(C) Æliens 20/2/2008

You may not copy or print any of this material without explicit permission of the author or the publisher. In case of other copyright issues, contact the author.