If what MS3FGX said doesn't work, you can set the router back to factory settings.
An unmodified linksys WRT-54G(S) uses that button for the 'easy security setup', if your using 3rd party firmware like dd-wrt, then that button usually turns the wireless radio on and off, if it is set to do so in the setup pages.
The first way to try is to log into the admin page with your browser, if you know it's current IP address, then go to the administration page and look for 'reset to factory defaults', check the box or whatever it requires then click 'apply settings'. You will then lose your connection while the router reboots but when its done you can log back into the router again by going to
http://192.168.1.1 and the default username= BLANK (no username) and password is 'admin' (no quotes).
If you cannot log into the router currently, then plug it in (turn it on), find the reset button in the rear, its small and a straightened paperclip or pencil tip will fit the hole. Press the button and hold it in for 30 seconds, then release the button, let it boot up (the lights will steady) and then log into it like described above, and like MS3FGX said too, "connect your computer up to it via one of the LAN ports." If this don't work the first time, try it again (push the button, wait thirty seconds, release...the router reboots, log in...you may have to get your PC to re-obtain an IP address from the routers DHCP, in order to connect.
Either way, your router will (should) be in the same state as when you bought it, you will have to reconfigure (for your network) again from the start