<!DOCTYPE HTML>
<html>
<head> </head>
<body>
<div id="artbl" style="width:500px;height:105px;border:1px solid #838383;background:#dddddd;padding:5px;">
<input type="button" onclick="addText()" value="+" id="buttaddpic"/>
<table id="con"><tr><td><span class="inp" size="1"> #1 </span><input type="text" size="55" id="skrinam" value=""></td></tr></table>
</div>
<script>
function addText() {
var taknum = parseInt(document.getElementsByClassName('inp').length);
if (taknum != 3) {
var vuii= taknum+1;
var qwe =document.getElementById('con').innerHTML;
*!*var tr = document.createElement('tr');*/!*
tr.innerHTML = '<td><span class="inp" size="1"> #'+ vuii +' </span><input type="text" size="55" id="skrinam'+vuii+'" value=""></td>';
*!*document.getElementById('con').appendChild(tr);*/!*
}
if (taknum == 3)
document.getElementById('buttaddpic').style.display = 'none';
}
</script>
</body>
</html>