Snes9x has the Keyboard set for the input set as Default. So if you have a Pad/Joystick the first stop is to set Pad/Joystick as Default.
Click on Options like the above Picture shows and then click Input.
Once the Dialogue opens, click on the Up Button Box like shot above shows. Use your Pad/Joystick to select the Digital/Analogue Up to set it to that. It will automatically move to the next Selection. Right, Down, Left, Select, Start, B, A, Y, X, Left and Right Triggers. Don't worry too much if you make a mistake, just click on the Box that is wrong and select the right one on your Pad/Joystick to continue the Auto next cycle.
You should end up with something like the shot shown above. Once you have made sure the settings are correct, click OK. The same applies if you want to change Buttons for the Keyboard. Just click on the Button and apply it to where you want it assigned for the use of the Keyboard. Now you are ready to start using a Pad/Joystick or Keyboard how you like it in your Games.