JQuery :: Selector With Collapsible Table Rows?
Jul 28, 2009
Im making a table that has collapsable/expandable rows and im having a bit of trouble. i started using the code from this site[URL].. post/20 lugin.aspx but where as this one has one row which is clickable to reveal the one underneath it, i need to reveal the next 2 underneath.
[Code]...
but this only reveals the first hidden row for the one i clicked. i need both to toggle. im new to jquery so havent mastered the selectors yet.
View 6 Replies
ADVERTISEMENT
Jul 4, 2006
I have been looking around for quite some time for a simple piece of code that allows rows to be collapsed in tables, so when you click on a link in the tbale the row beneath collapses. All i have found are very complex codes that i cant get to work or that dont work in both IE and FF.
View 6 Replies
View Related
May 3, 2010
I have some JQuery that makes an Ajax call and then adds some rows to an existing table.
function
LoadDestinationTable() {
$("#destinationTable tr:gt(0)"[code]...
The problem is that the only place where the click event fires is on the rows that were added when the page was 1st rendered – the th, for example.I also tried adding an onclick event handler to the input button’s creation – that also does not fire.
View 1 Replies
View Related
May 1, 2009
i'm creating a ASP page, which is going to have a form in it that needs filling out. part of the form will be a table with a header row, then the next rows will have text boxes that need filling out. is there a way of putting in a dropdown box that contatins numbers that will dynamically show the rows. for example if i select 5, then five rows of text boxes will appear. if i select 14 then 14 appear.
View 3 Replies
View Related
Jun 6, 2011
I have a need to select all table rows in the outer table of a cascading table structure, that is a table with contained tables. I tried to use the "Context" section of jQuery, but the table rows of the sub tables are being selected as well.
View 1 Replies
View Related
Feb 3, 2011
I have a site with 2 side by side tables with matching data. The left table is a drag-n-drop implementation so you can reorder the values in the database just by dragging and dropping. It works wonderfully. I want the right table to reflect the changes instantaneously. I got the right table to reload itself with the following jquery line:
$("#newMeet").load(location.href+" #newMeet>*","");
I stuck that line in the "Update" function of my "Sortable" funtion. And the line that I am using to initially stripe the right table is:
$(".checks2:even").addClass("grayBack");
Now matter where I stick that line, I cannot get the table re-striped after it reloads.
View 2 Replies
View Related
Jun 7, 2010
I have a dynamic HTML table which gets populated by coldfusion and displayed in the page, I have a column called performace which holds numeric values. I need to select the top 3 best performace value in the column and then highlight the entire row in different colours (top 3 values for performance). Can any one help me in doing it?My server can run only Javascript and coldfusion, No Ajax/PHP.I need a complete set of code which such that I will add the script and it performs the calculating and highlighting part.
View 1 Replies
View Related
Feb 9, 2011
Can I use script to remove the 2nd and 3rd table row elements from this html?
Code:
<table id="dap_product_links_table">
<tr>
<td><span class="scriptheader">Product Title</span></td>[code].....
View 3 Replies
View Related
Mar 20, 2011
this code works for me , but there is something wrong , every time the function loads (every 2.5 seconds )the html is loaded in row [0] cell[0] , and they are stacked above each other . what may be wrong there ?
code :
var searchtable=document.getElementById("searchtable")
var resultscount=0
[code]....
View 2 Replies
View Related
Jun 19, 2010
If I use an child selector like in [url] how can I prevent it from being applied to all tables?I need to select an child from only one table.
View 2 Replies
View Related
Feb 9, 2010
I have a table in which I have 3 columns. On the firs row, last column contain a button "save". On clicking Save, the button saved is changed to a delete button and it has to insert a new row above the row.
View 1 Replies
View Related
May 26, 2010
I would like to know what is wrong here that table rows/cols are not being inserted when using IE8, in FF and Chrome it works fine:What am I doing wrong?
var listFriends = eval(data.list);
var col = 0;
var ie8 = browser.isIE8;
[code]....
View 1 Replies
View Related
Jun 12, 2009
I've got a series of nested tables with data that look someting like this. [code]...
View 3 Replies
View Related
Dec 31, 2011
FIRST.:
when i create new rows, the function $("#test table tr").not(':first').mouseover(function(){
$(this).addClass("trcolor");
[code]...
View 1 Replies
View Related
May 15, 2009
Do you know if you can clone() and then appendTo() a <tr>. [URL]. I want to something like:
$("#second").clone().appendTo('#second');
It works, but it doesn't render like I want it to. I want it to be a NEW row.
View 1 Replies
View Related
Aug 19, 2009
confirm the syntax of what I am doingI have a table with id="tbl", it has 4 rows. I need to remove allrows except the first one.It has "tbody".Is this the way to do it$("#tbl > tbody > tr:gt(0)").remove();If this is the way to do it, it is not working
View 3 Replies
View Related
Jun 14, 2009
I am creating an admin section for a site I'm building. One of the options is to change the sort order of a list of items. I have all the backend (PHP) code running properly, but having a little issue with the jQuery. When the user clicks the Move Up link, how can I switch the table row containing the link they clicked on, and the one above it (row 3 becomes 2, and row 2 becomes 3)?
View 6 Replies
View Related
Apr 7, 2010
I want to be able to add and remove items (rows from a table). Right now i am able to add rows seemingly without any problem. And here is the thing I haven't been able to solve. When clicking on my image I can remove items that is created upon page load. But i can't remove items that I add after the page load, with the help of jQuery. My code
jQuery code:
$(document).ready(function() {
$('#addItem').click(function() {
var new_category = $('input#newCategory').val();
[Code]....
View 2 Replies
View Related
Nov 26, 2011
I have used jQ to replace table rows ok. For example,
Background [what works] A page with just js, html5, jQ, css: In the current page I view, I have a table id="Tbl1', with rows of the form
n=1,2,...
<tr id="Rn"> <td>...</td> <td>...</td> </tr>
var rid ='#R2';
var tr is anotherr row as above with n=2;
$(rid).replaceWith(tr); //will replace old row with new tr, matching the Rn. Good.
Also, I have another table id=Tbl2, in the same dom, but on a page that slides in and out using html5transition, on click. $('#Tbl2').append(tr); //works fine by appending to that Tbl2 (possiblyduplicatingrows)
[Problem] What is the exact syntax to do the $(rd).replaceWith(tr) operation on the contents of Tbl2. I have tried many combinations, but could not get it to work.
1. Looking for the syntax.
2. Incidiental question: Even though I have two tables, Tbl1, Tbl2, the first operation auto selects Tbl1 which appears second in the DOM after Tbl2.
View 1 Replies
View Related
Nov 6, 2010
So I've been trying to create a Spry table using SpryData pulling it from XML and then adding jQuery zebra stripe to the dynamic table.
Zebra Striping tutorial :[URR]
So far I have beenunsuccessfulat achieving thestripedtable :(, however, I did get the Spry to work and it builds the table perfectly.
SpryData tutorial: [URL]
Heres my sample page: [URL]
I am thinking I am either not using the selector correctly.
Or there is a conflict with jQuery and the Spry.
View 2 Replies
View Related
Jan 3, 2011
I have created a dynamic table to display data. I also added a checkbox field with a class name. I want to create a click event for when a user clicks on the checkbox. I can not get my selector to work.
Here is my code
function DynamicTable(data) {
var table = $("#grid");
table.html("");
[code]...
View 1 Replies
View Related
Oct 16, 2010
I'm building an application where the user can add Questions. For each Question they can add x answers or remove them (see screenshot). I can add questions and add/remove answers, For each question that is added I update the 'gameQuestions' variable with 1; The same goes for answers that I add: for each added answer I update the 'counter' variable with 1. When I remove an answer, the app. doesn't know how many answers each question has, it simply decreases the "counter" variable. So when I remove the 2nd question, it doesn't know how many answers that 2nd question has! How can I store the number of answers per question and how do I remove them correctly?
Here's my code so far:
$(document).ready(function(){
var gameQuestions = 1;
var counter = 1;
// Add a New Question...
$(".addQuestion").click(function() {
var question = "<table id='questionSet"+gameQuestions+"' class='form-table' style='background-color:#cccccc; width=100%;'>"; .....
View 1 Replies
View Related
Feb 22, 2011
Is it possible for jQuery to count the number of rows in a table and then add some more if there is less than a defined amount? So that this table with less than 10 rows.....
<table class="testTable">
<tr>
<td>Foo...</td><td>Foo...</td><td>Foo...</td>
</tr>
</table>
Becomes this...
<table class="testTable">
<tr><td>Foo...</td><td>Foo...</td><td>Foo...</td>
</tr><!--added by jQuery -->
<tr><td>...bar</td><td>...bar</td><td>...bar</td>
</tr><tr>
<td>...bar</td><td>...bar</td><td>...bar</td> .....
View 3 Replies
View Related
Feb 23, 2011
I'm trying to disable the onclick event on a ASP.NET gridview that generates following HTML markup:
<table id="GridViewPP" >
<tr >
<th scope="col">PP</th>
</tr>
<tr class="SelectedRow" onclick="javascript:__doPostBack('GridViewPP','Select$0')">
<td align="center">N</td>
[Code]...
View 2 Replies
View Related
Aug 24, 2011
I want to hide duplicate rows in a html table.
View 3 Replies
View Related
Nov 25, 2011
I'm a newbie to jQuery and I'm facing a "big" problem for my actual knowledge.. code...
If I run the code and click on "Delete" what I can obtain is only a partial remove of fields (the "Label4" and "Label5" still remains on the screen, all the others are removed)... but what I really need is a complete remove all of the "two" rows... I did many search on the forum but I wasn't able to find an answer .
View 5 Replies
View Related