Giter VIP home page Giter VIP logo

Comments (2)

MihaZupan avatar MihaZupan commented on June 6, 2024

This may happen because the hrefs defined by the website are using absolute paths instead of relative ones (assuming there's no prefix), redirecting the browser to a url without your prefix.
Or the website could return a 3XX redirect response that sends the browser to a different path or a different host entirely.
Or the website could be using JavaScript that does redirects.

You can try to fight such things by rewriting the response html, rewriting the location headers, etc., but this is difficult to do reliably.

Ideally, you'll want the websites behind the proxy to play nice and not make assumptions that they'll never be behind a proxy (generally this means proxying sites you own).
The better approach is generally to make changes to the website itself by correcting how it generates links/redirects, relying on things like the x-forwarded headers.

from reverse-proxy.

MihaZupan avatar MihaZupan commented on June 6, 2024

Closing as answered.
Feel free to reopen if there's something we missed.

from reverse-proxy.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.