search cancel

Notify-user with auto-redirect to different URL

book

Article ID: 173441

calendar_today

Updated On:

Products

ProxySG Software - SGOS

Issue/Introduction

You have to set Notify user that automatically redirect to different site after timeout.

Resolution

In Visual Policy Manager create new Web Access Layer...

1. Right click on Action>Set>>New...>Notify User>

2. Notify mode - check "Notify on every host"

3. Body:

<script type="text/javascript">

               setTimeout(function(){window.location.replace('https://test.site')},5000);

</script>

    <body onload="Accept();var notify_img=new Image(1,1);notify_img.src='$(exception.details)';">

        <p align=center><text align=center><b><span style='color:red'><h2>Important Notice!</h2></span></b></p>

        <p><b>System maintenance is scheduled for Sunday July 17, 2:00-4:00 am EST.</b></p>

        <p><b>To report any conflicts with the scheduled maintenance, see $(exception.contact)</b></p>

        <p><b>PLEASE NOTE:</b> Internet usage is routinely monitored and logged.</p>

        <p>Your IP address: $(client.address)<br>

        Your username: $(user)</p>

        <p>You will be connected in 5 seconds.</p>

    </body>

 

This script will redirect you to "test.site" after 5 seconds.