Editing and Delete problem Dynamically

This is a discussion on "Editing and Delete problem Dynamically" within the JavaScript Forum section. This forum, and the thread "Editing and Delete problem Dynamically are both part of the Program Your Website category.



Go Back   Webforumz.com > Main Forums > Program Your Website > JavaScript Forum

Notices


Reply
 
LinkBack Thread Tools
  #1 (permalink)  
Old Jun 27th, 2007, 11:43
New Member
Join Date: Jun 2007
Location: Karachi
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Editing and Delete problem Dynamically

Hi I am Scorp i have

Problem in Code i am unable to Correct it plz can anyone do correct it
i cant Delete the selected Row infact i am generating the Rows Dynamically but it always delete the row from starting Node..



<html>
<head>
<script type="text/javascript">

function loadPoll_name_onclick(){

var loadpollnamerow = document.getElementById("pollId");
var loadpollname = document.getElementById("pollname").value;


loadpollnamerow.innerHTML+="<div id='myDiv' style='border:1px solid #C0C0C0;'><span style='border:1px solid #C0C0C0;'><input type='button' value='Edit' ><input type='button' value='Delete' onclick='deletePoll_onclick()' /></span><span>" + loadpollname + "</span></div>";
}

function editPoll_onclick(){

}

function deletePoll_onclick(){

var d = document.getElementById("myDiv");
d.parentNode.removeChild(d);
}

function poll_name_onclick(){

}

function display_poll_question(pollname){

var pollquestion = document.getElementById(pollname);
pollquestion.style.display="block";

}
</script>

<style type="text/css">


a:link{
color: #333366;
text-decoration: none;
font-weight:bold;
}
a:visited{
color: #333366;
text-decoration: none;
font-weight:bold;
}

a:hover{
text-decoration: underline;
color: #333366;
font-weight:bold;
}

.poll{

border-style:solid;
border-width:1px 1px 1px 1px;
border-color: #C0C0C0;

position:absolute;
top:50px;
left:30px;
}

</style>
</head>

<body>

<div id="pollId" class="poll" >

<div style="width:350px;border:1px solid #C0C0C0; background-color:#808080;">
<span style="color:#FFFFFF; font-weight:bold;">Poll</span>
</div>

<div>
<b style="font-size:14px;">Poll Name :</b>
<input type='text' name='name' id="pollname" />
<input type='button' name='name' value='Submit Poll' onclick="loadPoll_name_onclick('pollId')">
</div>

<div style='border:1px solid #C0C0C0;'>
<span style='border:1px solid #C0C0C0;'>
<tr><td><input type='button' value='Edit'><input type='button' value='Delete'></td></tr>
</span>

<span >
<a id="pollname1">Country</a>
</span>
</div>

</div >
</body>
</html>
Reply With Quote

  #2 (permalink)  
Old Jun 29th, 2007, 13:21
New Member
Join Date: Jun 2007
Location: Karachi
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Editing and Delete problem Dynamically

Is there any to solve my Problem.....
Reply With Quote
Reply

Tags
problem

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
CSS editing tools danny322 Web Page Design 3 Feb 1st, 2008 17:40
Editing and Deleting Problem ScorpionKing Introduce Yourself 2 Jun 27th, 2007 19:07
by clicking on a dynamically generated button how can i delete a dynamictext box forjavascript JavaScript Forum 1 Nov 20th, 2006 21:02
Delete record problem Gee Bee Databases 2 Jan 4th, 2006 18:28
Problem opening page in dynamically generated iframe Malkalypse JavaScript Forum 3 Jun 20th, 2005 20:38


All times are GMT. The time now is 10:51.


Powered by vBulletin®
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0 RC8
© 2003-2008 Webforumz.com : All Rights Reserved

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43