Close browser from java code using specific url address

前端 未结 2 1666
天命终不由人
天命终不由人 2021-01-29 16:17

1) I want to close specific browser tab using url address from my java code. As it is a client server applicaiton. I want to close browser tab using url address from my client

2条回答
  •  孤城傲影
    2021-01-29 17:12

    You have to call a javascript to close the client's browser from your javascode. This is called reverse Ajax. You can achieve by using DWR framework. This a powerful API which help you to call Java from Javascipt and vice versa.

    By using this you can filter clients browser that are onto a specific URL.

    And this solution is not a OS specific it will work fine for every OS platform.

提交回复
热议问题