basically i want to echo out my results from a table but i want to use jquery as i want to be able to put a x button on each results then if that is clicked the results i removed from the page and also from the database i was thinking delete from the database and on delete refresh div that all the results are echo'd out into? does that make sence?
thanks ash
I would put a signature.. BUT, i don't have the time.
basically right i want to echo out the results like i currently am in php BUT if the user i admin i on hover a delete button will appear i can do that the show if admin the show on hover i cant not yet.. but the main thing is when that delete button is pressed i want that result to fade out and the other results to close in together as to say that result never existed but at the same time as fading out delete that record from the database...
I would put a signature.. BUT, i don't have the time.
ashwood wrote:but at the same time as fading out delete that record from the database...
That would ave to be done via an ajax request, I have no idea on all the visual stuff, but to make it remove from the db you want to use AJAX
Probably want to create a function that does the ajax request, and then shows an error if it fails, or removes the item if not.
[syntax=javascript]function remove_item(item_id){ // do things }[/syntax]
Then this function should be called using the onclick event for the X button or what ever you have,
see now i can work with the above and do the fading myself using jquery I THINK its a long shot but im going to have a go.. in that function you provided //do things.. could i not get it to call a php file that has the delete from... in it?
I would put a signature.. BUT, i don't have the time.