AJAX request with confirm and target blank window not working

Hi,
I’m trying to to run an AjaxHandler and open a blank tab upon a button click.
So I have

<a href="javascript:;" target="_blank" data-browser-target="_blank" data-request-confirm="Are you sure?" data-request="onUserEnroll" class="btn btn--block">Enroll now</a>

but it does not open a blank window that is supposed to received the redirect url from the AJAXhandler onUserEnroll

public function onUserEnroll() {
   return Redirect::to('https://google.com);
}

Hi @chris,

You can do that:

<a data-request="onLogin" data-request-success="window.open(data.result, '_blank');" class="btn btn-primary rounded-1" data-attach-loading="">
    Order online !
</a>

nice, thanks @apinard it works if the Ajaxhandle returns the url directly as a string.