tebrown Posted August 3, 2012 Share Posted August 3, 2012 Hey Guys, I have attached a link which shows my jsFiddle document. Basically what is happening is when i press the (x) on the right hand side, it closes all divs. I am trying to make it just close the specific one. Anyone be able to help me out? http://jsfiddle.net/tebrown/baCrx/ * Please excuse the messy css, i just copied it from my document as is. Cheers Browny Quote Link to comment https://forums.phpfreaks.com/topic/266631-javascript-help-jsfiddle-provided/ Share on other sites More sharing options...
Mahngiel Posted August 3, 2012 Share Posted August 3, 2012 You have a global scope of ".toggle" being removed on any X out. by providing a better scope using a class on the list item and .parents('selector') you can achieve your desired affect. http://jsfiddle.net/zv42a/1/ Quote Link to comment https://forums.phpfreaks.com/topic/266631-javascript-help-jsfiddle-provided/#findComment-1366578 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.