1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

Help with replacing video player

Discussion in 'PHP' started by chrisj, Jul 1, 2014.

  1. #1
    I'm using a video web site script and have successfully (with help) replaced the main video player on the site. However, there is a small player in the SiteAdmin that shows "Error Loading Media" most definitely caused by the changes I've made. Here is the current code related to SiteAdmin player, that shows "Error Loading Media" when I select the 'play' arrow:

    <!--start of PHP-Player -->
    <script type="text/javascript">
    var flashvars = {};
    var params = {};
    var attributes = {};
    flashvars.flvsource = "[var.base_url]/uploads/[var.video_play]";
    flashvars.autoplay = "false";
    flashvars.color_nav_bar_top = "0x478dc2";
    flashvars.color_nav_bar_bottom = "0xE7EBEC";
    flashvars.ads_background_color = "0x00CCFF";
    flashvars.ads_border_color = "0xCCCCCC";
    flashvars.scrubber_position_color = "0x6AA1CE";
    flashvars.scrubber_load_color = "0x888888";
    flashvars.scrubber_background_color = "0xBBBBBB";
    flashvars.volume_bar_color = "0xBBBBBB";
    flashvars.buffering_time = 1;
    flashvars.aspect_ratio="stretch";
    params.allowfullscreen = "true";
    params.allowscriptaccess = "sameDomain";
    swfobject.embedSWF("[var.base_url]/player.swf", "myAlternativeContent", "245", "192", "9.0.0", false, flashvars, params, attributes);
    </script>
    <!--end of PHP-Player -->
    Code (markup):
    Here are the two files that have to do with the site's main video player that's working successfully:

    make_player.htm:
         
    <video id="_1200k.mp4" class="video-js vjs-default-skin"
    preload="none" width="445" height="340" controls
    poster="[var.thumb_file]" data-setup='{techOrder: [‘flash’,’html5’}'>
         
    <source src="http://new.player.com.s3.amazonaws.com/[var.video_play]" type='video/mp4' />
         
    <object class="vjs-flash-fallback" width="445" height="340" type="application/x-shockwave-flash" data="https://releases.flowplayer.org/swf/flowplayer-3.2.1.swf">
    <param name="movie" value="/flowplayer/flowplayer-3.2.16.swf" />
    <param name="allowfullscreen" value="true" />
    <param name="flashvars" value='config={"playlist":["/[var.thumb_file]", {"url": "http://new.player.com.s3.amazonaws.com/[var.video_play]","autoPlay":false,"autoBuffering":true}]}' />
    <!-- Image Fallback. Typically the same as the poster image. -->
    <img src="[var.thumb_file]" width="640" height="264" alt="Poster Image" title="No video playback capabilities." />
    </object>
    </video>
    PHP:
    AND

    inner-play.html:
    
    <div id="container22ABCD"><div class="container-player333">
    <div style="height:340px;overflow:hidden;"><center>
    <iframe src="/make_player.php?vid=[var.vid]&player_token=[var.player_token]" style="width:450px; height:340px; border:none;" marginheight="0" scrolling="no" name="flvplayer">
    <!--[onload;block=iframe;when [var.video_type] != 'embedded';comm]-->
    </iframe>
    <!--start of EmbedVideo Addon Player-->
    <span>
    <!--[var.videoembedder_code;htmlconv=no;comm]-->
    <!--[onload;block=span;when [var.video_type] == 'embedded';comm]-->
    </span>
    <!-- end of EmbedVideo Addon Player-->
    </center></div>
    </div></div>
    PHP:
    Can you help me change the SiteAdmin player to work successfully based on what I've provided?
     
    chrisj, Jul 1, 2014 IP