Simple transformerless power supply
This is a low current transformerless power supply for small applications. The capacitor C1 reduces the high volt AC. D1-D4 rectifies AC to DC and C2 reduces ripples. R1 discharge stored energy in C1 to avoid electric shock when power is off. R2 limits inrush current. The Zener diode is used to get regulated DC output.
 -The Zener value can be changed to get other output voltages.
If you don’t have a zener diode use normal diodes in series for exemple 3 diodes in series give 1.8v-2.2v depending on the load current.
– The value of the capacitor determines the maximum output current, now let’s calculat’it it’s easy…: 
  1. First we calculate the impedance of the circuit (C1 and R2): Zc+R2 = (1/(2*pi*F*c))+R2 = (1/(314*0.0000022))+100 = 1547Ω. 
  2.  Second we calculate the voltage across C1 and R2: V-Vz-Vd = 230-12-1.4 =216V. (( V (main AC) Vz (Zener voltage) Vd (voltage drop across diode brige 1.4v) )).
  3. Third the max current: 216/1547 = 140 mA.
Use the same calculations for other values.

Ask if you have any questions.