That unfortunately hides the whole page. It goes completely blank in both FF and IE7. :-(
On Apr 11, 9:44 am, [EMAIL PROTECTED] wrote: > [BDY.TXT]try this: > > $(function() { > $('"#' + imgToShow + '"').hide(); > > }) > -----Original Message----- > From: andreas [mailto:[EMAIL PROTECTED] > Sent: Wednesday, April 11, 2007 3:19 PM > To: jquery-en > > Cc: andreas > Subject: [jQuery] Variable in selector > > I'm trying to hide an image, and I have the id of that image in a > variable (imgToShow). Here's what I'm trying: > > $("#"+imgToShow).show(); > > This is not working. What am I doing wrong?