In the web GUI goto "wpa_gui" setup tool and connect to an existing WLAN and youre done !
You can do that manually as well in editing /etc/network/interfaces

allow-hotplug wlan0
iface wlan0 inet dhcp
wpa-ssid YourSSID
wpa-psk YourPassword

You can also leave the default
allow-hotplug wlan0
iface wlan0 inet dhcp
wpa-roam /etc/wpa_supplicant/wpa_supplicant.conf

and simply edit the /etc/wpa_supplicant/wpa_supplicant.conf file with the following

ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev
update_config=1
eapol_version=1
ap_scan=1
network={
ssid="yourssid"
scan_ssid=1
key_mgmt=WPA-PSK
pairwise=CCMP
group=CCMP
psk=your password
}

To not copy your key in cleartext you can calculate the passphrase with
wpa_passphrase yourssid yourpassword

which should give you something like this:
psk=01b035e084c87e1a3e348e6fbb4783202b145950789c69 1687ee0a6f71584e8b