Detecting if YouTube is blocked by company / ISP

前端 未结 5 2038
心在旅途
心在旅途 2020-12-05 19:27

We have YouTube videos on a site and want to detect if it is likely that they will not be able to view them due to (mostly likely) company policy or otherwise.

We ha

5条回答
  •  慢半拍i
    慢半拍i (楼主)
    2020-12-05 20:14

    This should work. Basically, it loads a youtube.com javascript file, then checks if a function in that file exists.

    
    
    
        
        
    
    
    
        
    
    
    
    
    

提交回复
热议问题