How to handle Modal dialog

How to handle Modal dialog using selenium library.

I have been using:

Handle Alert Accept

you have other options to choose different buttons in the dialog, but usually I just hit warning messages that pop-up as an alert.