Replace content in a label with that of another file

Currently I have a label

<asp:label id="lblTerms" runat="server">
         You can see our full <a onclick="FullTerms();">Terms & Conditions.</a>
</asp:label>

That calls this function:
<script language="JavaScript">
        function FullTerms(){
                  document.getElementById('lblTerms').innerHTML = " ";
                  document.getElementById('lblTerms').innerHTML = loadPage("test.htm");
            }
      </script>

But it's not working.

I want to load the test.htm file and replace it in the lblTerms label. Thanks
wilcor14Asked:
Who is Participating?
 
madpatConnect With a Mentor Commented:
The best way to do this with ajax, here is an example:
http://textsnippets.com/posts/show/602

Without ajax you can use this example:
http://javascript.internet.com/page-details/load-html.html
 
0
All Courses

From novice to tech pro — start learning today.