Functions init, alert