The trick is to stop trying to configure everything from Amarok and go instead to the new System Settings application.
Click on the Network Settings icon under Network & Connectivity:
Next, enter the settings appropriate for your network. Note that these settings will be used by Amarok 2 and other KDE applications:
Next, go to the Settings menu in Amarok 2 and select Configure Amarok. Click on the Internet Services Icon, then click on the little monkey wrench in the Last.FM item:
When you click on the Test Login button the button text will change to Testing. Within a few seconds it should change to Success! If it does not say Success after a while there is a problem remaining to be found somewhere.