i have a little problem with jQuery. I want to append ID for element from other element after that i click on it… 🙂 So, if i click some list element this element id will go to another, can you hel me? This is my code…
$('#main_menu li').click(function(){
(this.id).appendTo('.main_content ul')
})
Here
this.idwill get the clicked elementidand set thatidto.main_content ul.But this will make
idduplication, which is not allowed.Instead of
idyou can makeclass: