How to fix an error of website iframe?

2019-03-06 17:44发布

问题:

When I go to this url : (warning: some Ad-blocker is recommended)

https://openload.co/embed/M4pSomdJWME/?c1_file=http://tugaflix.com/legendas/716bac991518958ad95df18200c906c3.srt&c1_label=Legenda

The web-page link loads fine, without errors.

However, when I try to load same page via iframe in my html code, an error appears:

My html code :

<html>
    <head>
    </head>
    <body>
        <iframe width="600" height="700" 
        src="https://openload.co/embed/M4pSomdJWME/?c1_file=http://tugaflix.com/legendas/716bac991518958ad95df18200c906c3.srt&c1_label=Legenda">
        </iframe>
    </body>
</html>

Below image: Error result within my iframe. How to fix such error?

回答1:

If you're willing to design/code your own player interface then one loading option is to use a <video> tag instead of via <iframe> tag...

<video width="640" height="480" controls crossorigin="anonymous">
<source src="https://oload.stream/stream/M4pSomdJWME~1508775093~213.205.0.0~IzmpIUe0?mime=true" type="video/mp4">
</video> 

I'm not going to tell you how to steal access any video by code, but some advice is:

1) You can see in the source code that a server 1508775191~213.205.0.0 is accessed for media files including subtitle VTT file). Study rest of source code. Consider why token is mentioned and why referrer is checked. What can you do pass and get same access?

2) By using your browser's Developer Tools (especially "network" and "console" tabs), you can find the related https://oload.stream/stream/ url for any future updates or alternate embeds.

PS:

"but, this tugaflix.com/Episodio?E=2310910&S2 website is using that iframe"

Look at source code of: http://tugaflix.com/Episodio?E=2310910&S2/
You will see that no iframe is mentioned or used... They are even using two different player interfaces so you cannot assume that tugaflix.com is loading this page https://oload.stream/embed/M4pSomdJWME within some iframe. They are instead accessing the MP4 video file from some server calledhttps://lemonade-fruit.fruithosted.net/



回答2:

The target site has code that prevents it from being shown in an Iframe. Unfortunately you will not be able to use that url in an Iframe.