View Full Version : Printing out ...

08-13-2005, 12:51 PM
I am hopelessly lost here.I am playing around with Ajax, but Javascript has stumped me.

Here is my code:

<input type="text" name="x" id="x" value="2" size="3" /> *
<input type="text" name="y" id="y" value="3" size="3" /> =

<!-- This works if uncommented -->
<!-- <input type="text" name="z" id="z" value="" size="3" /> -->

<!-- Is this area correct? -->
<script type="text/javascript">
<!-- Is it? -->

<input type="button" value="Calculate" onclick="xajax_multiply(document.getElementById('x').value,document.getElementById('y').value);return false;" />

That gives me the right output in an input box when this is uncommented:

<input type="text" name="z" id="z" value="" size="3" />

However, I don't want the output in the textbox, rather just printed out. What changes do I need to make to do this?

08-13-2005, 06:42 PM
What is the Ajax code. That appears to be what is setting the third textbox. Since nothing you wrote here says where to output it.