Bug 484617 - Browser doesn't show iframe contents anymore
Summary: Browser doesn't show iframe contents anymore
Status: CONFIRMED
Alias: None
Product: plasmashell
Classification: Plasma
Component: Web Browser widget (show other bugs)
Version: 5.27.11
Platform: Fedora RPMs Linux
: NOR normal
Target Milestone: 1.0
Assignee: Plasma Bugs List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-03-27 19:28 UTC by t.baag
Modified: 2025-03-21 16:56 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments
Embed page seems to be considered a popup and therefore blocked (75.41 KB, image/png)
2024-03-27 19:29 UTC, t.baag
Details
Screenshot demonstrating it functioning. (656.81 KB, image/png)
2024-11-17 22:39 UTC, Roke Julian Lockhart Beedell
Details
my html iframe background (not working anymore) (529.18 KB, application/gzip)
2024-11-20 19:29 UTC, t.baag
Details
Minimum reproduction HTML file. (461 bytes, text/html)
2024-11-20 20:02 UTC, Roke Julian Lockhart Beedell
Details
Demonstration screenshot. (25.11 KB, image/png)
2024-11-20 20:06 UTC, Roke Julian Lockhart Beedell
Details
Demonstration screencast. (2.52 MB, video/mp4)
2024-11-20 20:12 UTC, Roke Julian Lockhart Beedell
Details
A Minimal Reproduction HTML File (563 bytes, text/html)
2025-03-21 00:09 UTC, Roke Julian Lockhart Beedell
Details

Note You need to log in before you can comment on or make changes to this bug.
Description t.baag 2024-03-27 19:28:16 UTC
SUMMARY

The plasma webbrowser widget doesn't show iframe contents anymore. It seems it considers them as popups which are blocked.


STEPS TO REPRODUCE
1. Create a html with iframe, object or embed tags to embed a website.

OBSERVED RESULT

A "content blocked" panel where the content should be.

EXPECTED RESULT

Rendering the contents as it was in Plasma 5.

SOFTWARE/OS VERSIONS
Linux/KDE Plasma: Arch Linux
KDE Plasma Version: 6.0.2
KDE Frameworks Version: ?  
Qt Version: 6

ADDITIONAL INFORMATION

Happend after dreaded update to Plasma 6.
Comment 1 t.baag 2024-03-27 19:29:00 UTC
Created attachment 167860 [details]
Embed page seems to be considered a popup and therefore blocked
Comment 2 Roke Julian Lockhart Beedell 2024-11-17 22:39:13 UTC
Created attachment 175893 [details]
Screenshot demonstrating it functioning.

(In reply to t.baag from comment #1)

It works for me.

> ```YAML
> Operating System: Fedora Linux 41
> KDE Plasma Version: 6.2.3
> KDE Frameworks Version: 6.8.0
> Qt Version: 6.8.0
> Kernel Version: 6.11.7-300.fc41.x86_64 (64-bit)
> Graphics Platform: Wayland
> Processors: 12 × AMD Ryzen 5 7600X 6-Core Processor
> Memory: 30.4 GiB of RAM
> Graphics Processor: AMD Radeon RX 5700
> Manufacturer: ASRock
> Product Name: X670E Taichi
> ```
Comment 3 t.baag 2024-11-20 19:05:00 UTC
I was trying "file:///home/bla/blubb.html" over here which worked in plasma 5.
Comment 4 Roke Julian Lockhart Beedell 2024-11-20 19:07:12 UTC
(In reply to t.baag from comment #3)
Please upload the file (and any of its associated resources, in a single archive) so that I can reproduce it for ya.
Comment 5 t.baag 2024-11-20 19:29:46 UTC
Created attachment 175979 [details]
my html iframe background (not working anymore)

I last used the thingy with plasma 5, so it's somewhat outdated now. Also 80% of the screen is covered with websites only working in the lan over here. But thanks for looking into it.
Comment 6 Roke Julian Lockhart Beedell 2024-11-20 19:59:07 UTC
(In reply to t.baag from comment #5)

I see [the attached screenshot][1] when I open it, and the blocked popup button takes me to [`embed.windy.com`][2]. That seems to match what you describe.

Considering [`#c2`][3], this makes the issue appear to be dependent upon the HTML file being accessed via the `file:` URI schema. To verify, are you able to host this on a webserver, or even just run it through NodeJS on `localhost` (so that you're connecting via HTTP(S))? I'd be perplexed if it didn't work there, yet worked at W3S (as aforedemonstrated).

My lazier method of verification was to merely replace an iframe with a YouTube one, which indeed didn't work:

```HTML
<!doctype html>
<html>
  <head>
    <meta charset="utf-8">
    <title>Fenstergucker</title>
  </head>
<body style="margin:0; padding:0; overflow: hidden">

  <iframe src="https://nagios.ide.ezbb.de/nagios/cgi-bin/status.cgi?host=all&servicestatustypes=28" style="position: absolute; top: 0; left: 0%; width:25%; height: 100%"></iframe>
  <!--iframe src="https://nagios.ide.ezbb.de/nagios/cgi-bin/status.cgi?host=all&servicestatustypes=28" style="position: absolute; top: 0; left: 0%; width:25%; height: 40%"></iframe-->
  <!--iframe src="https://chat.ide.ezbb.de/channel/general" style="position: absolute; top: 40%; left: 0%; width:25%; height: 60%"></iframe-->

  <iframe src="https://wekan.ide.ezbb.de/b/Z6gZm7vGeTthKpjPJ/tho-todo" style="position: absolute; top: 0; left: 25%; width:25%; height: 50%"></iframe>
  <iframe src="https://wekan.ide.ezbb.de/b/mYRNzBN6tg2YxSvyW/backup" style="position: absolute; top: 50%; left: 25%; width:25%; height: 50%"></iframe>

  <iframe src="https://wekan.ide.ezbb.de/b/NqHQkbKZQpKG64giJ/mta-problemberichte" style="position: absolute; top: 0; left: 50%; width:25%; height: 50%"></iframe>
  <iframe src="https://wekan.ide.ezbb.de/b/46dZrbZBGa7H9gDtS/issues-problemeberichte" style="position: absolute; top: 50%; left: 50%; width:25%; height: 50%"></iframe>

  <!--iframe src="https://www.wetteronline.de/wetterradar/berlin/lichtenberg?wrg=10382&wrh=true&wrn=TGljaHRlbmJlcmc=&wrx=50.92,11.79&wry=52.52,13.48&wro=true&wrm=6" style="position: absolute; top: 0; left:75%; width:25%; height: 55%; margin-top: -3%;" scrolling="no"></iframe-->
  <iframe id="windy" src="https://embed.windy.com/embed2.html?lat=52.527&lon=12.483&zoom=6&level=surface&overlay=rain&menu=&message=&marker=&calendar=&pressure=true&type=map&location=coordinates&detail=true&detailLat=52.527&detailLon=13.510&metricWind=default&metricTemp=default&radarRange=-1" style="position: absolute; top: 0; left:75%; width:25%; height: 50%;" scrolling="no"></iframe>
  <iframe id="twitter-sbahn" style="position: absolute; top: 50%; left: 75%; width:13%; height: 50%"></iframe>
  <iframe id="twitter-bvg-tram" style="position: absolute; top: 50%; left: 88%; width:13%; height: 25%"></iframe>
  <iframe id="bvg" src="http://mobil.bvg.de/Fahrinfo/bin/stboard.bin/dox?input=+Ev.+Krankenhaus+KEH+%28Berlin%29&REQ0JourneyStopsSID=A%3D1%40O%3DEv.+Krankenhaus+KEH+%28Berlin%29%40X%3D13508648%40Y%3D52525481%40U%3D86%40L%3D900160520%40B%3D1%40p%3D1550151426%40&HWAI%3DJS%21js=yes&HWAI%3DJS%21ajax=yes&REQ0HafasUnsharpSearch=1&existUnsharpSearch=yes&start=Suchen&boardType=depRT" style="position: absolute; top: 75%; left: 88%; width:12%; height: 25%"></iframe>
  <script type="text/javascript">
    // reload windy
    window.setTimeout("document.getElementById(\"windy\").src += \"\"", 3000);
    window.setInterval("document.getElementById(\"windy\").src += \"\"", 300000);
    // reload bvg
    window.setInterval("document.getElementById(\"bvg\").src += \"\"", 18000000);
    // twitter sucks that hard it's unbelivable
    twitter_embed = function ( elementId, url) {
      document.getElementById(elementId).contentDocument.body.innerHTML = "<a class=\"twitter-timeline\" href=\""+url+"\">Tweets</a>";
      var twitterscript = document.getElementById(elementId).contentDocument.createElement('script');
      twitterscript.type = "text/javascript";
      twitterscript.src = "https://platform.twitter.com/widgets.js";
      document.getElementById(elementId).contentDocument.body.appendChild( twitterscript )
    }
    twitter_embed( "twitter-sbahn", "https://twitter.com/SBahnBerlin?ref_src=twsrc%5Etfw" );
    twitter_embed( "twitter-bvg-tram", "https://twitter.com/BVG_Tram" );
  </script>
</body>
</html>
```

...However, I then tested a downloaded version of [the `iFrame` W3S page][4] via SingleFile, and it worked perfectly.

Consequently, are you certain that there is no issue with your code? I ask because QtWebEngine may well have updated its internal Chromium version, which can be expected to break compatibility with certain ways of doing things, if those methods were merely incidentally supported previously.

[1]: https://drive.google.com/file/d/1d6NCDb_845MFLr_cGVkFmtIUm2evqRw_/view?usp=sharing
[2]: https://embed.windy.com/embed2.html?lat=52.527&lon=12.483&zoom=6&level=surface&overlay=rain&menu=&message=&marker=&calendar=&pressure=true&type=map&location=coordinates&detail=true&detailLat=52.527&detailLon=13.510&metricWind=default&metricTemp=default&radarRange=-1
[3]: https://bugs.kde.org/show_bug.cgi?id=484617#c2
[4]: https://www.w3schools.com/html/html_iframe.asp
Comment 7 Roke Julian Lockhart Beedell 2024-11-20 20:02:01 UTC
Created attachment 175981 [details]
Minimum reproduction HTML file.

(In reply to Roke Julian Lockhart Beedell from comment #6)

Ah, ignore that. Apologies. I've created [a minimum viable W3C-valid HTML file][1] with an iframe, and the described behaviour can be reproduced. I'll attach it to provide a more scientific way of testing when this has been fixed.

[1]: https://stackoverflow.com/revisions/13441795/2#:~:text=from%20W3C%20at-,https://www.w3.org/QA/2002/04/valid%2Ddtd%2Dlist.html,-answered%20Nov%2018%2C
Comment 8 Roke Julian Lockhart Beedell 2024-11-20 20:06:42 UTC
Created attachment 175983 [details]
Demonstration screenshot.
Comment 9 Roke Julian Lockhart Beedell 2024-11-20 20:12:23 UTC
Created attachment 175984 [details]
Demonstration screencast.

I've also uploaded this to [YouTube][1] so it's easier to watch.

[1]: https://www.youtube.com/watch?v=1VfczZf1Qpo&t=2s#:~:text=+-,2024%2D11%2D20T19:43:05+00:00%5BEurope/London%5D,-%5Bca%2Diso8601%5D
Comment 10 Roke Julian Lockhart Beedell 2024-11-20 20:13:58 UTC
I had to change the package type to Fedora for me to bump it to 6.2.3. To my knowledge, KDE Bugzilla uses the last reproduced version for the version field, not the first, and I can reproduce it in a later version.
Comment 11 Roke Julian Lockhart Beedell 2024-11-20 20:16:19 UTC
(In reply to t.baag from comment #3)
Do you happen to know which version of Plasma 5 it last worked in? Even if not the latest version, just knowing a version helps (since Plasma 5 was around for so long).
Comment 12 t.baag 2024-11-20 20:21:29 UTC
It looks like plasma-workspace-5.93 was the last version before switching to 6 in Arch. It also matches the time of my bug report somewhat.

Thanks for investing your time.
Comment 13 Nate Graham 2025-03-19 23:31:26 UTC
t.baag@keh-berlin.de, please provide a way to reproduce the issue, either a local HTML file or a URL for a web location. Thanks!
Comment 14 Roke Julian Lockhart Beedell 2025-03-21 00:09:09 UTC
Created attachment 179619 [details]
A Minimal Reproduction HTML File

(In reply to Nate Graham from comment #13)  
> please provide a way to reproduce the issue, either a local HTML file or a URL

The undermentioned does:

> <!DOCTYPE html>
> <html lang="en-GB-oxendict">
> 	<head>
> 		<title>Example Document</title>
> 	</head>
> 	<body>
> 		<iframe
> 			id="inlineFrameExample"
> 			title="Inline Frame Example"
> 			width="300"
> 			height="200"
> 			src="https://www.openstreetmap.org/export/embed.html?bbox=-0.004017949104309083%2C51.47612752641776%2C0.00030577182769775396%2C51.478569861898606&amp;layer=mapnik">
> 		</iframe>
> 			<!-- https://developer.mozilla.org/en-US/docs/Web/HTML/Element/iframe#try_it:~:text=%3Ciframe,%3C/iframe%3E -->
> 	</body>
> </html>
> 	<!-- https://validator.w3.org/nu/#textarea -->

> Operating System: Fedora Linux 41
> KDE Plasma Version: 6.3.3
> KDE Frameworks Version: 6.12.0
> Qt Version: 6.8.2
> Kernel Version: 6.13.7-200.fc41.x86_64 (64-bit)
> Graphics Platform: Wayland
Comment 15 Nate Graham 2025-03-21 16:56:54 UTC
Thanks, can confirm.