<div id="add" style="display:none;" width="660" >内容<input type="text" size="35" id="value1" maxlength = "256">网址<br><input size="45" type="text" id="value2"><input type="submit" value="Submit" onClick="OnAdd()"></div>
<div id="add" width="660" >内容<input type="text" size="35" id="value1" maxlength = "256">网址<input size="45" type="text" id="value2"><input type="submit" value="Submit" onClick="OnAdd()"></div>
HTML code
That’s because you have other styles. Who knows how to write your code.
Write this code into a separate file and see what it looks like.
The parent element is not long enough.
There is no float.
This is just a part of the code. You have posted all the CSS styles of the parent element.
<div id="add" width="660" >内容<input type="text" size="35" id="value1" maxlength = "256">网址<input size="45" type="text" id="value2"><input type="submit" value="Submit" onClick="OnAdd()">……