jquery onclick for expanding text content on the right?


Hi I am trying to achieve the same effect as it is on hover on my fiddle, I would like to use jquery click/toggle to expand the content instead of seeing it on hover

I am trying the basic addClass with jquery/css but somehow it’s breaking off and cannot figure it out how to work properly

Would appreciate any help or advice on the following, thanks a lot in advance,

here is the fiddle i created with the jquery I am using



Problem courtesy of: dikei


Sorry I am a bit late to the game but here is the solution:


Since you have multiple gamewrapper classes, you need to reference the ‘this’ keyword to specify the clicked element, then look for it’s children to apply the CSS changes.

More details on the jQuery click event handler here: http://api.jquery.com/click/

Solution courtesy of: Woodchipper

View additional discussion.