OK - should be simple - but pulling my hair out

OK - should be simple - but pulling my hair out

Hello:

I'm trying to use jQuery to do a simple show(), hide().... at this point though I've been entirely unsuccessful.

  1. Goal: show() - hide() command buttons depending on what pages the users are in. There are two buttons. If the user is in survey.php the <INPUT TYPE="button" id="survey_image" class="inline_bttn"... should hide(), else the same button should show(). Once I get this goal solved, I'll want to add another command button should hide() on main.php and show() on survey.php. Following is my current routine.

  1.     if(var_ParseURL[4]=='survey.php')
  2.     {
  3.         $('#survey_image').hide();
  4.         console.log("inside survey if"); // This console.log works - so I know the if is working.
  5.     }
  6.     else
  7.     {
  8.     $('#survey_image').hide();
  9.     }
The console.log("inside survey if"); // This console.log works - so I know the if is working. on line 4 is working. But still... the <input button does not hide.

Any advice about this matter would be greatly appreciated.

Thanks Much:

Pavilion