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

    [RESOLVED] Aviod popping up logout page and manual address logout

    Scheduled Pinned Locked Moved Captive Portal
    6 Posts 4 Posters 8.8k 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.
    • Z
      zcache
      last edited by

      Hi all,
      many few day ago I tried to make a modified captive portal code in section of logout page to avoid a popup logout windows. and I tried with my office, it's working correct with feature.
      1. no popping up windows
      2. call back a logout page by address like 192.168.0.1:8000
      completely testing on pfsense release 2.0 x86 platform

      so would like to share with other platform maybe helpful.  ;D

      Download Captiveportal.rar code
      it containing with 3 files

      • captiveportal.inc
        original location \etc\inc\

      • index.php
        original location \usr\local\captiveportal

      • services_captiveportal.php
        original location \usr\local\www

      to make a try, turn off your captive portal first, replace those files with correct location and start your captive again
      pls. share is it working with other??


      ** post move from http://forum.pfsense.org/index.php/topic,38856.0.html

      PF-Sense 2.0.2
      Freelance IT Developer

      1 Reply Last reply Reply Quote 0
      • Z
        zcache
        last edited by

        add automatic redirect in 5 sec
        edit file captiveportal.inc

        add new meta tag in section of …....

        ex.

        <title>{$g['product_name']}</title>

        PF-Sense 2.0.2
        Freelance IT Developer

        1 Reply Last reply Reply Quote 0
        • F
          fsantaana
          last edited by

          thanks Zcache!!

          this worked great in my setup!! helped avoid alot of problems with customers complaining about logging out.

          now my next challenge is to convert the user input to lowercase as to avoid headaches with incorrect usernames because of case-sensitive. (Specially true with IOS devices and the first letter defaulting to caps!)

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

            Hello.
            How can I replace the files?

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

              Oh, i found it! Web Interface -> Diagnostics -> Edit File

              1 Reply Last reply Reply Quote 0
              • C
                clart
                last edited by

                I have seen in other captive portals where the word "logout" is typed in browser address bar.

                This is much simpler  solution, but how to implement it?

                It needs some intercept/analysis of http request for word "logout" and then redirect to the logout URL.
                Maybe this could be put in captive portal code or squid proxy config or where?

                Also, would be useful to type "status" into address bar and get page back showing time remaining, etc.

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