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

    Adding banner to webpage

    Scheduled Pinned Locked Moved pfSense Packages
    5 Posts 2 Posters 3.4k 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.
    • F
      filip_pag
      last edited by

      hello :),

      is it possible with squid/squid3 to add banner in the top of every webpage
      that user opens? i have a hotspot and in the top of users screen i want to
      write "internet access is sponsored by …" is it possible?
      i found this:
      http://squid-web-proxy-cache.1019090.n4.nabble.com/Display-company-Banner-with-SQUID-td1036552.html
      can you tell me how to do it?

      ps. sorry for my bad english :D

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

        Probably possible if redirect to self page-container.

        SquidGuardDoc EN  RU Tutorial
        Localization ru_PFSense

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

          self page container? can you please explain?

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

            @filip_pag:

            self page container? can you please explain?

            My idea is:

            Write PHP page myBanner.php and put it to pfSense www catalog

            Add squidGuard destinations myBanner

            • Filter Adware by specific attribute (url as ad, adХХ, banner and etc)
            • Redirection setup to http://pfSenseIP:Port/myBanner.php?url=%u      (http://www.squidguard.org/Doc/redirect.html)

            Set deny this myBanner rule in ACL

            Page myBanner.php must make you self banners

            SquidGuardDoc EN  RU Tutorial
            Localization ru_PFSense

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

              $Img1 = "http://t1.gstatic.com/images?q=tbn:ANd9GcTAsTI-8z4O3D42H_OWG2fcJEm6AVxqu0-7H0Q7OArTtBDYgDR5";
              $Alt1 = "[advertisement] nesto";
              $Url1 = "http://www.google.com";

              $Img2 ="http://www.pro-dezign.com/images/banner.jpg";
              $Alt2 = "[advertisement] pro-dezign web development";
              $Url2 = "http://www.pro-dezign.com/index.html";

              $num = rand (1,2);

              $Image = ${'Img'.$num};
              $Alt = ${'Alt' .$num};
              $URL = ${'Url'.$num};

              Print "["".$Alt."""; ? >

              and just place the PHP include on your page where you want the banner rotator.]("".$URL."")

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