Or another option is to use a confirm box instead ...
# suitescript
m
Or another option is to use a confirm box instead of an alert box, and one of the buttons will open the link