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

    multiple html files? (different languages)

    Scheduled Pinned Locked Moved Captive Portal
    4 Posts 3 Posters 1.0k 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.
    • 2
      21hertz
      last edited by 21hertz

      Hi!

      I sent our translation "team" to translate our captiveportal page to several languages. I have now received several HTML pages (copies of the original english one) that I have uploaded via File Manager. According to the documation I should be able to link to the files uploaded via File manager but it's not possible to click the language links from the main cp-page (links to cp_site_spanish.html, cp_site_french.html etc) - you get re-directed to the original cp-page no matter what you link to on locally.

      The only way to make this work is to do it in PHP then? My PHP skills are weak at best and I don't have the time to learn how to do it right now from scratch (if it's not easy to do in the current index.php page).
      We do not use username/password - only an informational site with Accept button to login.

      Any tips would be helpful!

      pfSense user for 8+ years on network with 5k+ active users.

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

        I have the same problem.
        Did oyu solve it?

        2 1 Reply Last reply Reply Quote 0
        • 2
          21hertz @Airparker
          last edited by

          @airparker No I didn't..

          pfSense user for 8+ years on network with 5k+ active users.

          H 1 Reply Last reply Reply Quote 0
          • H
            heper @21hertz
            last edited by

            should be fairly simple with some php or javascript bs

            something like:
            https://github.com/knuch/js-lang-redirect
            or
            https://stackoverflow.com/questions/66438076/redirect-user-based-on-their-language-preference-in-js
            or
            https://stackoverflow.com/questions/18098528/detecting-browser-language-in-php-and-redirect
            or
            https://stackoverflow.com/questions/41995878/php-language-redirect-automatically

            you could also not redirect but use a case statement to include the different languages as required.

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