我已經設置了一個框以顯示來自Ajax表單的結果,顯示來自美國地質調查局的水數據並使用Google圖表。很好用,但我希望用戶在第一次加載表單而不是空白框時看到一些示例結果。不知道該怎麼做。下面是窗體的代碼:將Ajax示例結果顯示爲表單加載
<table bgcolor="tan" width="480px" height="450px"><tr><td>
<h2>Current River Levels</h2></td><td>
<form>
<select name="users"; onchange="showUser(this.value); drawChart(this.value)";>
<option value="01598500">North Branch at Luke, MD</option>
<option value="01603000">North Branch at Cumberland, MD</option>
<option value="01610000">Potomac River at Paw Paw, WV</option>
<option value="01613000">Potomac River at Hancock, MD</option>
<option value="01619500">Antietam Creek at Sharpsburg, MD</option>
<option value="01638500">Potomac River at Point of Rocks, MD</option>
<option value="01648000">Rock Creek at Sherrill Drive, DC</option>
<option value="01646500">Little Falls, DC</option>
</select>
</form></td></tr><td colspan="2">
<div id="placeholder"></div>
<div id="placeholder2"></div>##
<div id="chart" style="width:100%"></div>
<div id="txtHint"><b>Select a site or visit our <a href="../monitoring_map.php4" target="_blank">interactive map.</a></b></div>
整個項目位置爲:http://www.riverexplorer.com/potomax/json_test_20.php
只是加載頁面加載一些示例數據... – m02ph3u5