Alert box before Redirecting

Hi all

I have a form.On filling the details and clicking submit,i would like to
pop up an alert box if the form was saved successfully before
redirecting to the entry's show page.
Kindly Help.