PDA

View Full Version : Question on Dynamic Ajax Content



Kirlaskia
12-16-2005, 01:25 AM
http://www.dynamicdrive.com/dynamicindex17/ajaxcontent.htm

Is there a script to have something be like that, only instead of opening a link in the right hand side, just have whatever text you want to input?

Thanks!

Veronica

ddadmin
12-16-2005, 11:11 PM
Hmmm the whole purpose of Ajax is to retreive a file that already exists on the server. If you're looking to display text based on something you enter, just DHTML will suffice. For example:


<div id="test">Old text</div>

<script type="text/javascript">
document.getElementById("test").innerHTML="new text"
</script>

Twey
12-17-2005, 10:50 AM
Well, it will suffice if you remember to put in the slash in the end-DIV tag and specify type="text/javascript" for the SCRIPT, of course :p

ddadmin
12-17-2005, 10:15 PM
What you talkin' bout Twey, they were there to begin with! :D

Kirlaskia
12-17-2005, 11:53 PM
I figured it out, thanks for all the help!