Welcome Guest 
メインメニュー
ログイン

ユーザー名:


パスワード:





パスワード紛失
トップ  >  HTML  >  tableタグをカンマ区切りで記述するJS

tableタグをカンマ区切りで記述するJS

<html>
<body>
<script>
function tr(td){
document.write("<tr><td>"+td.replace(/^\s+|\s+$/g,'').replace(/\s*,\s*/g,',').split(",").join("</td><td>")+"</td></tr>");}
</script>

<table border=1><script>
tr("abc,def,ghi,jkl,mno");
tr("123,456,789,012,345");
</script></table>

</body>
</html>

プリンタ用画面
友達に伝える
投票数:43 平均点:10.00
カテゴリートップ
HTML

XOOPS Cube PROJECT
Powered by XOOPS Cube 2.2 © 2001-2012 XOOPS Cube Project