User Profile
Collapse
-
thatcollegeguy replied to $("td").click(function() { $(this).empty(); } will work for table in html but not phpin JavascriptAnother question: will using this xml technique have implications if the website has two people logged in at the same time? -
thatcollegeguy replied to $("td").click(function() { $(this).empty(); } will work for table in html but not phpin JavascriptThanks for trying to help DMsy2
The answer lies in the livequery plugin for jquery.
First, I installed the plugin.
Second, I inserted this code in the js file:
Code:$('td') .livequery('click', function(event) { $(this).empty(); return false; });Leave a comment:
-
thatcollegeguy replied to $("td").click(function() { $(this).empty(); } will work for table in html but not phpin JavascriptKept the other change and changed the .js element to td #tbl as the id of the generated table is 'tbl', but didn't allow any td items to empty. So I changed the page back to how it was after my original change. It currently only empties after the submit button is clicked.Leave a comment:
-
thatcollegeguy replied to $("td").click(function() { $(this).empty(); } will work for table in html but not phpin Javascriptquick question, are you able to view the webpage in question at http://smarterfootball.com/exits/theHTML.html ?Leave a comment:
-
thatcollegeguy replied to $("td").click(function() { $(this).empty(); } will work for table in html but not phpin JavascriptI made your first suggested change. As you can see, the only difference is that now, you cannot empty the table below the button until the top table is generated after the button is clicked.Leave a comment:
-
thatcollegeguy started a topic $("td").click(function() { $(this).empty(); } will work for table in html but not phpin Javascript$("td").click(function() { $(this).empty(); } will work for table in html but not php
http://smarterfootball.com/exits/theHTML.html
I am not sure what is wrong w/ this code. The main issue is that the table that is in the initial html will empty its td but the table that I load using php and jquery through a mysql database will not empty the td elements. There is a table underneath the button in the initial html. if you click on a box in the table, it will empty. the same does not happen for the table that is generated... -
thatcollegeguy replied to Created table using Ajax but can't change td inner html for a specific table elementin Javascriptit's on line 285 - addSchool(str) in teamreports.js
if you still think your solution can solve the problem - what changes can I make in order to fix it?
Thanks!Leave a comment:
-
thatcollegeguy replied to Created table using Ajax but can't change td inner html for a specific table elementin JavascriptI just used firebug to get a better idea of the code that is showing in my html page after the first basic ajax change. I assumed that I missed a </td> to make it not work correctly, but this was not the case. Maybe this can help someone help me debug the current coding.
...Code:<td id="add73" valign="bottom"> <div id="ad73"> <form method="post"> <input
Leave a comment:
-
thatcollegeguy started a topic Created table using Ajax but can't change td inner html for a specific table elementin JavascriptCreated table using Ajax but can't change td inner html for a specific table element
Below are my 3php and 2js files.
I create a table using ajax/php and then want to change the values in the tables add(+ number for teamid) id's for each specific td in the table. I don't know if I have the entirely wrong approach, but my code is below. Any or all help is appreciated!
What currently happens is that the getdivision.php script works perfectly and gives me an entire table of correct data. The problem is...
No activity results to display
Show More
Leave a comment: