<textarea> <br> aaaaaaaaaaaaaa <br><br> cccccccccc <br> dddddddddddd <br> fffffffffffff <br> </textarea> <br> <input> <br> <input> <br> <script> <BR> function goL(Line) <BR> { <BR> ta1.focus(); <BR> var v=ta1.value.split('\n'); <BR> ch=0; <BR> for(var i=0;i<Line-1;i++) <BR> ch+=v[i].length; <BR> var o=ta1.createTextRange(); <BR> o.move("character",ch); <BR> o.select(); <BR> } <BR> </script><br><div class="htmlarea"><textarea id="runcode77248"> <textarea name="ta1" rows="5" cols="50"> aaaaaaaaaaaaaa bbbbbbbbbbbbbb cccccccccc dddddddddddd fffffffffffff <input value="1" name="line"> <input type="button" onclick="goL(parseInt(line.value));" value="go"> <script> function goL(Line) { ta1.focus(); var v=ta1.value.split('\n'); ch=0; for(var i=0;i<Line-1;i++) ch+=v[i].length; var o=ta1.createTextRange(); o.move("character",ch); o.select(); } </script> </textarea><br><input onclick="runEx('runcode77248')" type="button" value="运行代码"> <input onclick="doCopy('runcode77248')" type="button" value="复制代码"> <input onclick="doSave(runcode77248)" type="button" value="保存代码">[Ctrl+A 全选 注:<a href="http://www.jb51.net/article/23421.htm" title="查看具体详情" target="_blank">如需引入外部Js需刷新才能执行</a>]</textarea></div>