/    Sign up×
Community /Pin to ProfileBookmark

how to add column in table

Hi ,
i want to add columns in table by clicking the button “Add col”

here is my script
<html>
<body>
<div id=Table1></div>
<input type=”Button” value=”Enter columns” OnClick=”EnterCol()”>

<div id=Table1>
<table border=1>
<tr>
<td>Id(No)</td>
<td>ABC(kbps)</td>
<td>XYZ(kbps)</td>
</tr>

<script type=”text/vbscript”>
For i =1 to 4
Document.write(“<tr>”)
Document.write(“<td >” & i & “</td>”)
abc = 20 * i
xyz = 10*
i
Document.Write “<TD>” & abc & “</TD>”
Document.Write “<TD>” & xyz & “</TD>”
Document.write(“</tr>”)
Next
</script>
</table>
</div>
</body>

<head>
Function Entercol()
End Function
</head>
</html>

Can anybody tell me what will be my script in EnterCol function.
My column should be after “xyz” columns.

to post a comment
HTML

1 Comments(s)

Copy linkTweet thisAlerts:
@gizmoJun 07.2005 — You are more likely to get an answer in the Javascript forum.
×

Success!

Help @kya_karey2002 spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 5.19,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @AriseFacilitySolutions09,
tipped: article
amount: 1000 SATS,

tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,
)...