Advertisement
Guest User

Untitled

a guest
Mar 23rd, 2017
106
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 7.99 KB | None | 0 0
  1. <?php
  2. $dt_player = get_post_meta($post->ID, 'repeatable_fields', true);
  3. $width = get_option('dt_width_layout','1100');
  4. $light = get_option('dt_player_luces','true');
  5. $report = get_option('dt_player_report','true');
  6. $ads = get_option('dt_player_ads','not');
  7. $qual = get_option('dt_player_quality','true');
  8. $viewsc = get_option('dt_player_views','true');
  9. $clic = get_option('dt_player_ads_hide_clic','true');
  10. $time = get_option('dt_player_ads_time','20');
  11. $ads_300 = get_option('dt_player_ads_300');
  12. $dt_maindrop = dt_get_meta('dt_backdrop');
  13. $dt_runtime = dt_get_meta('runtime');
  14. // Reportar templante
  15. get_template_part('inc/parts/single/report-video');
  16. // Player
  17. ?>
  18. <style> .jw-preview.jw-reset { background-image: url('<?php echo "https://image.tmdb.org/t/p/w780".$dt_maindrop ?>'); background-size: cover; } </style>
  19. <div id="playex" class="player_sist">
  20. <?php if ( $dt_player ) : ?>
  21. <div class="playex">
  22. <?php if ($ads =='true') : ?>
  23. <div id="playerads" class="ads_player">
  24. <div class="ads_box">
  25. <div class="ads">
  26. <?php if($ads_300) : echo '<div class="code">'. stripslashes($ads_300). '</div>'; endif; ?>
  27. <?php if ($clic =='true'): ?><span class="notice"><?php _e('انقر فوق الإعلان لإغلاق','mtms'); ?></span><?php endif; ?>
  28. </div>
  29. </div>
  30. </div>
  31. <?php endif; ?>
  32. <?php $numerado = 1; { foreach ( $dt_player as $field ) { ?>
  33. <?php if($field['select'] == 'iframe') { ?>
  34. <div id="option-<?php echo $numerado; ?>" class="play-box-iframe fixidtab">
  35. <iframe id="iframe_" class="metaframe rptss" src="<?php
  36. if (preg_match("/drive/",$field['url'])){
  37. $field['url'] = base64_encode($field['url']);
  38. echo 'http://www.moviflex.net/player/embed2.php?url='.$field['url'];
  39. }
  40. else {
  41. echo $field['url'];} ?>" frameborder="0" scrolling="no" allowfullscreen="true"></iframe>
  42. </div>
  43. <?php } if($field['select'] == 'mp4') { ?>
  44. <div id="option-<?php echo $numerado; ?>" class="play-box-mp4 fixidtab">
  45. <?php echo do_shortcode('[video src="' . $field['url'] .'" width="'. $width .'px" autoplay="false"]'); ?>
  46. </div>
  47. <?php } if($field['select'] == 'dtshcode') { ?>
  48. <div id="option-<?php echo $numerado; ?>" class="play-box-shortcode fixidtab">
  49. <?php echo do_shortcode($field['url']); ?>
  50. </div>
  51. <?php } if($field['select'] == 'mfPlayer') { ?>
  52.  
  53.  
  54. <div id="option-<?php echo $numerado; ?>" class="play-box-mp4 fixidtab">
  55.  
  56.  
  57. <?php
  58. ?>
  59. </div>
  60. <?php } $numerado++; } } ?>
  61. <div id="player_bg">
  62. <i class="bg_drop an" style="background-image: url('<?php echo "https://image.tmdb.org/t/p/w780".$dt_maindrop ?>')";></i>
  63. <span class="pulse-ring"></span>
  64. <i class="play_bg an"></i>
  65. <a href="#play" class="play_infos fade-transition an" onclick="removePlay()">
  66. <i style="background-image: url('http://www.moviflex.net/wp-content/uploads/2017/03/s_assets_play.png');" class="play_ico an"></i>
  67. <div class="infos_ an">
  68. <?php if (have_posts()) :while (have_posts()) : the_post(); ?>
  69. <h2 class="m_name"><?php the_title(); ?></h2>
  70. <div class="beside_">
  71. <span class="quality_t">
  72. <?php if ($qual =='true') : if($quali = $terms = strip_tags( $terms = get_the_term_list( $post->ID, 'dtquality'))) { ?><?php echo $quali; ?><?php } endif; ?>
  73. </span>
  74. <span style="margin-left: 5px;">
  75. <?php echo $dt_runtime; ?>Min
  76. </span>
  77.  
  78. </div>
  79. <div class="beside_">
  80. <i class="icon-eye an"></i>
  81. <span style="margin-left: 5px;">
  82. <?php if ($viewsc =='true') : if($views = dt_get_meta('dt_views_count')) { echo $views; } endif; ?>
  83. </span>
  84. </div>
  85. <?php endwhile; endif; ?>
  86. </div>
  87. </a>
  88. </div>
  89. </div>
  90. <?php endif; ?>
  91. <div class="control">
  92. <nav class="player">
  93. <ul class="options">
  94. <li>
  95. <a><i class="icon-menu"></i> <b><?php _e('سيرفر','mtms'); ?></b></a>
  96. <?php if ( $dt_player ) : ?>
  97. <ul class="idTabs">
  98. <?php $numerado = 1; { foreach ( $dt_player as $field ) { ?>
  99. <li><a class="options" href="#option-<?php echo $numerado; ?>">
  100. <?php echo $field['name']; ?>
  101. <?php if($field['idioma']=='nn') { /* none */} else { ?><span class="dt_flag"><img src="<?php echo DT_DIR_URI, '/assets/img/flags/',$field['idioma'],'.png'; ?>"></span><?php } ?>
  102. </a></li>
  103. <?php $numerado++; } } ?>
  104. </ul>
  105. <?php endif; ?>
  106. </li>
  107. </ul>
  108. </nav>
  109. <?php if ($qual =='true') : if($quali = $terms = strip_tags( $terms = get_the_term_list( $post->ID, 'dtquality'))) { ?><span class="qualityx"><?php echo $quali; ?></span><?php } endif; ?>
  110. <?php if ($viewsc =='true') : if($views = dt_get_meta('dt_views_count')) { echo '<span class="views"><strong>'. $views .'</strong> '. __('المشاهدات','mtms') .'</span>'; } endif; ?>
  111. <nav class="controles">
  112. <ul class="list">
  113. <?php if ($ads =='true') : ?><li id="count" class="contadorads"><?php _e('الإعلان','mtms'); ?> <i id="contador"><?php echo $time; ?></i></li><?php endif; ?>
  114. <?php if ($light =='true') : ?><li><a class="lightSwitcher" href="javascript:void(0);"><i class="icon-wb_sunny"></i></a></li><?php endif; ?>
  115. <?php if ($report =='true') : ?><li><a class="report-video"><i class="icon-textsms"></i></a></li><?php endif; ?>
  116. </ul>
  117. </nav>
  118. </div>
  119. <?php if($_GET[ 'report' ] =='send') { send_report(); } ?>
  120. </div>
  121. <script type='text/javascript'>
  122. $(document).ready(function(){
  123. $("#oscuridad").css("height", $(document).height()).hide();
  124. $(".lightSwitcher").click(function(){
  125. $("#oscuridad").toggle();
  126. if ($("#oscuridad").is(":hidden"))
  127. $(this).html("<i class='icon-wb_sunny'></i>").removeClass("turnedOff");
  128. else
  129. $(this).html("<i class='icon-wb_sunny'></i>").addClass("turnedOff");
  130. });
  131. });
  132. <?php if ($ads =='true') : ?>
  133. var segundos = <?php echo $time; ?>;
  134. function ads_time(){
  135. var t = setTimeout("ads_time()",1000);
  136. document.getElementById('contador').innerHTML = '' +segundos--+'';
  137. if (segundos==0){
  138. $('#playerads').fadeOut('slow');
  139. $('#count').fadeOut('slow');
  140. clearInterval(setTimeout);
  141. }
  142. }
  143. ads_time();
  144. <?php endif; ?>
  145. <?php if ($clic =='true'): ?>
  146. $(".code").click(function() {
  147. $("#playerads").fadeOut("slow");
  148. $("#count").fadeOut("slow");
  149. });
  150. $(".notice").click(function() {
  151. $("#playerads").fadeOut("slow");
  152. $("#count").fadeOut("slow");
  153. });
  154. <?php endif; ?>
  155. $( ".options" ).click(function() {
  156. $( '.rptss' ).attr( 'src', function ( i, val ) { return val; });
  157. });
  158. </script>
  159. <script>
  160. function removePlay() {
  161. document.getElementById('player_bg').style.display = "none";
  162. }
  163. </script>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement