Django (web framework): What are the Best Practice For Displaying another Website from yours?
1st December 2012
My answer to Django (web framework): What are the Best Practice For Displaying another Website from yours? on Quora
This isn’t really a Django-specific question—the answer would be the same no matter what server-side tech you use.
The problem with iframes is that some websites have frame-busting JavaScript to prevent then from being framed. It’s not possible to detect this, so it’s always possible that a site you try to iframe will break your page.
A better alternative is to show a rendered preview image of the page. This is very tricky to implement (PhantomJS is a good starting point) but there are web services that can solve this for you for a fee—like http://www.url2png.com
More recent articles
- Qwen2.5-Coder-32B is an LLM that can code well that runs on my Mac - 12th November 2024
- Visualizing local election results with Datasette, Observable and MapLibre GL - 9th November 2024
- Project: VERDAD - tracking misinformation in radio broadcasts using Gemini 1.5 - 7th November 2024