Web-bugs: v.pptv.com - video or audio doesn't play

Created on 2 Oct 2017  路  9Comments  路  Source: webcompat/web-bugs



URL: http://v.pptv.com/show/icWM9uibBXPnzfXcU.html?rcc_src=B3

Browser / Version: Firefox 58.0
Operating System: Windows 10
Tested Another Browser: Yes

Problem type: Video or audio doesn't play
Description: the video feed does not start
Steps to Reproduce:
I try to watch a Chinese drama fr om the browser, it did work on FF ver. 55, but not work on FF ver56 and FF Nightly built ver.58. I tried it on latest Chrome and it workd.

Screenshot Description

_From webcompat.com with 鉂わ笍_

browser-firefox priority-normal type-stylo

Most helpful comment

We'll try to contact with PPTV, also to see whether they have plans to drop flash.

All 9 comments

@bli-mozbj could you help to test this issue? I know it needs Flash Player, but I can't play video even if enable Flash player.

capture d ecran 2017-10-04 a 12 43 18

The code sent is different depending on the user agent. For example if you send the Safari iOS user agent it will send a video element with a link (unfortunately HLS).

The player is initialized by
http://player.aplus.pptv.com/jsplayer/pid/5701.js

They try to detect flash

    v = function () {
      try {
        return new ActiveXObject('ShockwaveFlash.ShockwaveFlash')
      } catch (e) {
      }
      try {
        return navigator.plugins['Shockwave Flash']
      } catch (e) {
      }
      return !1
    },

They detect the useragent

  agent = window.navigator.userAgent,
  encode = encodeURIComponent,
  isMobile = !!agent.match(/(iPhone|iPod|Android|iPad|BlackBerry|webOS)/i),

which they use here:

    this.playVideo = function (e) {
      if ('' !== e && void 0 !== e || s.playVideo(), 'number' == type(e) && p.playList[e]) {
        d = e,
        o._willPlay = !0;
        var t = p.playList[d];
        return s || log('player null.'),
        s.playVideo(t)
      }
      'object' == type(e) && o.resetList([e])
    },
    this.checkPlayerType = function (e) {
      return e = + e,
      100000 > e || 950000 > e && e > 300000 ? 'live' : 'vod'
    },
    this.goToAndPlay = function (e, t) {
      var a = + new Date,
      n = t || {
      },
      i = n.ctx && n.ctx.stime > - 1 ? 'live' : this.checkPlayerType(e);
      if (log('褰撳墠鎾斁绫诲瀷 goToAndPlay ===>', i, isMobile, e, n), n.cid = e, mix(n, n.ctx), this.lastTime) {
        if (a - this.lastTime < 1000) return;
        this.lastTime = a
      } else this.lastTime = a;
      if ('live' == i) {
        var r = + new Date / 1000 >> 0,
        l = n.ctx || {
        };
        l.etime && r >= Number(l.etime) && (n.isVod = 1)
      }
      return n.swfUrl ? (this.loadSWF(n.swfUrl), void (n.swfUrl = null))  : void (!s || isMobile ? s = this.create(this.config)  : this.getConfig().playerType != i ? this.switchPlayer(mappid[i], e)  : o.playVideo(n))
    },
    this.switchPlayer = function (e, t) {
      s = null,
      PPTVPlayer = null,
      Loader.load({
        url: l.replace(/\[pid\]/i, e),
        type: 'js',
        userCall: !1,
        callback: function () {
          log('switchPlayer ===> ', e, t),
          o.getVideoData(t)
        }
      })
    },

If they detect flash, they send object and embed.

All of that is done through an iframe.

<iframe id="ifr_player" allowfullscreen="" mozallowfullscreen="" webkitallowfullscreen="" src="http://player.aplus.pptv.com/corporate/proxy/proxy.html#id=12179709&amp;autoplay=0&amp;w=100%25&amp;h=100%25&amp;pageUrl=http%3A%2F%2Fm.pptv.com%2Fshow%2FicWM9uibBXPnzfXcU.html%3Frcc_src%3DB3&amp;pageRefer=&amp;videoType=vod&amp;ctx=complete%3D1%26poster%3Dhttp%253A%252F%252Fv.img.pplive.cn%252F63%252F91%252F63911e4964c579df1a194bc0b25bed56%252F3.jpg%26kk%3D85a666038480a4050fb50bb1cfe60005-d622-59ddcbb4%26o%3Dm.pptv.com%26isVipMovie%3D0%26isSport%3D0%26msiteSourceSite%3D&amp;adConfig=chid%3D10031555%26clid%3D0" scrolling="no" height="100%" frameborder="0" width="100%"></iframe>

Pushing to needscontact and @MDTsai though honestly I don't think they will change anything for NON HLS. Maybe they are preparing for a flashless world and it would be worth to attempt to contact them and encourage them to adopt different formats.

We'll try to contact with PPTV, also to see whether they have plans to drop flash.

Already fixed and verified on Firefox 56&58
PPTV is still in the process of switching to HTML5 player, but no timeline for the launch yet.

Let's close this issue as fixed, thanks for the help of @bli-mozbj

Was this page helpful?
0 / 5 - 0 ratings