Skip to content
Advertisement

JQuery Get Data From Onther Div to Li

I want this operations using jQuery. On image click The item should add to the menu. Suppose I click on pizza image the it should add new li in ul with name pizza. When I again click on image 1 that pizza should be gone. This is code:

JavaScript

Advertisement

Answer

Working Fiddle

Your HTML:

JavaScript

Some jQuery:

JavaScript

Voila!

Advertisement