alert
is special in the fact that it blocks until the user responds to the popup. Generally in JS this is a big no-no, because if you block, you'll block the entire user interface. This precludes using a jQuery modal popup as a direct replacement for alert
. You need to modify the software to use callbacks instead of synchronous alerts. (Most of) JS is event-based and single-threaded, and there isn't really a way around that.
There is a function called showModalDialog which shows a modal popup window (the kind we all hate), but that's pretty much it. It originated from IE, but as Pekka pointed out it's also implemented in Firefox 3 or newer and based on a quick Google search Webkit seems to have some support for it as well. It's still not a neat in-page popup though.