6
J
u
l
y
2
0
0
5
Dom
Question: how do you dynamically add content to a web page without going back to the server?
Answer: with some Javascript which manipulates the Document Object Model.
Something which I hadn’t felt like handling until recently cropped up as being the best way to solve a problem. My mind is now full of createElement, appendChild and setAttribute methods.
Hooking DOM stuff into Ajax is another cool way of building a page without recourse to lots of intermediate saves or page reloads. Then, when you’re done, you can bung the completed page, maybe containing a form, back to the server. Super. Okay, so I’ve not done the Ajax bit yet, but, gee, how hard can it be?

Leave a Reply