Netgate Discussion Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Search
    • Register
    • Login

    Time left @ Logout page

    Scheduled Pinned Locked Moved Captive Portal
    5 Posts 4 Posters 1.9k Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • K
      Kababayan
      last edited by

      I want the username, ipaddress and time left to appear in the logout page or redirection page after authentication. Time left will refresh after refreshing the page. or some1 can gve a better code to automatically refresh the time left every n seconds. What are the variables for the said data? I tried this but username is blank. :
      echo "Welcome  = ";
              echo $username;      // also tried $sessionid still blank
              echo "Youre ipadress = ";
              echo getenv('REMOTE_ADDR');
      echo "remaining time = ";
              echo ''; // I dont know
          ?>
      I use freeradius 2 in pfsense 2.1. Hope some 1 can help.

      1 Reply Last reply Reply Quote 0
      • M
        mendilli
        last edited by

        for the username and ip;open captiveportal_logout.html which is in "/var/etc"

        add this line anywhere you want to display the client username and client ip

        LogoutWin.document.write('USERNAME =

        ');
        LogoutWin.document.write('YOUR IP =

        ');

        1 Reply Last reply Reply Quote 0
        • D
          dpsapao
          last edited by

          Is it working?

          1 Reply Last reply Reply Quote 0
          • A
            asistio04
            last edited by

            @mendilli:

            for the username and ip;open captiveportal_logout.html which is in "/var/etc"

            add this line anywhere you want to display the client username and client ip

            LogoutWin.document.write('USERNAME =

            ');
            LogoutWin.document.write('YOUR IP =

            ');

            Thank you for this ,,,tested and working

            1 Reply Last reply Reply Quote 0
            • M
              mendilli
              last edited by

              @asistio04:

              @mendilli:

              for the username and ip;open captiveportal_logout.html which is in "/var/etc"

              add this line anywhere you want to display the client username and client ip

              LogoutWin.document.write('USERNAME =

              ');
              LogoutWin.document.write('YOUR IP =

              ');

              you are very welcome

              Thank you for this ,,,tested and working

              1 Reply Last reply Reply Quote 0
              • First post
                Last post
              Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.