<script type="text/javascript"
src="prototype.js"></script>
[HTML]
<div id="targetBox">
ここのエレメントに対して Insertion.Topが実行される。
</div>
:
:
[JavaScript]
// "targetBox"エレメントの最初の要素にテキストを挿入します
new Insertion.Top("targetBox", "<b>挿入したテキスト</b>");
[Ajax - prototype.js - 文字列の挿入・変更]
エレメントの前に文字列を挿入する 【Insertion.Before】
エレメントの終了タグの後に文字列を挿入する 【Insertion.After】
エレメントの末尾に文字列を挿入する 【Insertion.Bottom】
エレメントの内容を変更する 【Element.update】