2

私の会社のウェブサイト http://www.lta.org.uk/にはJW5.9Playerがあります。IOSやその他のモバイルデバイスをサポートするようにコードを更新しようとしています。私が間違っていることについての洞察をいただければ幸いです。私はHTML/CSSの知識を持つデザイナーですが、この開発者についてはわかりません。再度、感謝します。

http://www.lta.org.uk/の現在のライブサイト(iOSでは機能しません)は次のコードを使用しています:

<div id="Flash"></div>
    <script type="text/javascript">
       var flashvars = {
            "file": "<%= this.File %>",
            "image": "<%= this.PreviewImage %>",
            "autostart": "<%= this.AutoStart%>",
            "skin": "<%= this.Skin%>",
            "dock": "true",
            "controlbar.position": "bottom",
            "stretching": "fill"
            <%if(!String.IsNullOrEmpty(PlaylistPath)){%> 
                 ,"playlist":           "right",
                 "playlist.thumbs": "false",
                 "playlistsize":        "172",
                 "playlistfile":        "<%=PlaylistPath%>"
            <%}else if(!System.String.IsNullOrEmpty(this.File) && this.File.Contains("yospace.com")){%>
                ,"provider": "video"
            <%}%>
       };
       var params = {
       "allowfullscreen": "<%=this.AllowFullScreen%>",
          "allowscriptaccess":  "always",
          "wmode":              "transparent"
       };
       var attributes = {
       "id": "<%=this.ClientID%>",
       "name": "<%=this.ClientID%>"
       };


       swfobject.embedSWF("/swf/LTA-player.swf", "<%=DivMediaPlayer.ClientID%>", "<%=Width%>", "<%=Height%>", "9", "false", flashvars, params, attributes);



    </script>
</div>

私はそれを更新して、うまくいけばこれでiOSで動作するようにしました:

 <div id="Flash"></div>

    <script type="text/javascript" src="/javascript/jwplayer.js"></script>

    <script type="text/javascript">
    if(swfobject.hasFlashPlayerVersion("1"))
       {
           console.log('flash');
       var flashvars = {
            "file": "<%= this.File %>",
            "image": "<%= this.PreviewImage %>",
            "autostart": "<%= this.AutoStart%>",
            "skin": "<%= this.Skin%>",
            "dock": "true",
            "controlbar.position": "bottom",
            "stretching": "fill"
            <%if(!String.IsNullOrEmpty(PlaylistPath)){%> 
                 ,"playlist":           "right",
                 "playlist.thumbs": "false",
                 "playlistsize":        "172",
                 "playlistfile":        "<%=PlaylistPath%>"
            <%}else if(!System.String.IsNullOrEmpty(this.File) && this.File.Contains("yospace.com")){%>
                ,"provider": "video"
            <%}%>
       };
       var params = {
       "allowfullscreen": "<%=this.AllowFullScreen%>",
          "allowscriptaccess":  "always",
          "wmode":              "transparent"
       };
       var attributes = {
       "id": "<%=this.ClientID%>",
       "name": "<%=this.ClientID%>"
       };


       swfobject.embedSWF("/swf/LTA-player.swf", "<%=DivMediaPlayer.ClientID%>", "<%=Width%>", "<%=Height%>", "9", "false", flashvars, params, attributes);
        }
        else
        {


    jwplayer("<%=DivMediaPlayer.ClientID%>").setup({
                flashplayer: "/swf/lta-jwplayer.swf",
                file: "<%= this.File %>",
                image: "<%= this.PreviewImage %>",
                height: "<%=Height%>",
                controlbar: "bottom",
                width: "<%=Width%>",
                autostart: "<%= this.AutoStart%>",
                skin: "<%= this.Skin%>",
                id: "<%=this.ClientID%>",
                name: "<%=this.ClientID%>",
                dock: 'true',
                <%if(!String.IsNullOrEmpty(PlaylistPath)){%> 
                    playlist:           "right",
                    playlist.thumbs:    "false",
                    playlistsize:       "172",
                    playlistfile:       "<%=PlaylistPath%>"
                <%}else if(!System.String.IsNullOrEmpty(this.File) && this.File.Contains("yospace.com")){%>
                    provider: "video"
                <%}%>
            });
        }   


    </script>

</div>
4

0 に答える 0