ブログとかのタグ挿入みたいなやつ 例) <html> <head> <script type="text/javascript"> //ボタン用 function insert(text){ var str = text; //テキストエリア位置取得 document.getElementById("area").focus(); var selection = document.selection.createRange(); //テキストエリアの位置に取得した内容をセット selection.text = str+selection.text; } //プルダウン用 function puru(form) { //プルダウンのValueの中身を取得 var index = form.select1.selectedIndex; var str = form.select1.option
