Guest User

Untitled

a guest
Oct 18th, 2020
96
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 5.63 KB | None | 0 0
  1. <?php
  2. /**
  3. *
  4. * @ This file is created by http://DeZender.Net
  5. * @ deZender (PHP7 Decoder for ionCube Encoder)
  6. *
  7. * @ Version : 4.1.0.1
  8. * @ Author : DeZender
  9. * @ Release on : 29.08.2020
  10. * @ Official site : http://DeZender.Net
  11. *
  12. */
  13.  
  14. function halimPlayerInit($post_id, $episode_link, $episode_type, $tracks, $list_sub, $list_sub_label)
  15. {
  16. if (has_filter('halim_custom_player_types')) {
  17. $obf_DT0kEiwCGj4WHj8fARUFXBQsORAfMgE = apply_filters('halim_custom_player_types', (object) ['post_id' => $post_id, 'link' => $episode_link, 'episode_type' => $episode_type, 'player_type' => '', 'subtitle' => $list_sub, 'sublabel' => $list_sub_label, 'sources' => '']);
  18.  
  19. if ($obf_DT0kEiwCGj4WHj8fARUFXBQsORAfMgE->player_type == 'custom_api') {
  20. $sources = $obf_DT0kEiwCGj4WHj8fARUFXBQsORAfMgE->sources;
  21. halimBuildPlayer($post_id, $sources, $tracks, $obf_DT0kEiwCGj4WHj8fARUFXBQsORAfMgE->link);
  22. }
  23. else if ($obf_DT0kEiwCGj4WHj8fARUFXBQsORAfMgE->player_type == 'custom_iframe') {
  24. if ($obf_DT0kEiwCGj4WHj8fARUFXBQsORAfMgE->sources) {
  25. echo $obf_DT0kEiwCGj4WHj8fARUFXBQsORAfMgE->sources;
  26. }
  27. else {
  28. halim_detect_embed(['post_id' => $post_id, 'link' => $obf_DT0kEiwCGj4WHj8fARUFXBQsORAfMgE->link, 'subtitle' => $obf_DT0kEiwCGj4WHj8fARUFXBQsORAfMgE->subtitle, 'sublabel' => $obf_DT0kEiwCGj4WHj8fARUFXBQsORAfMgE->sublabel]);
  29. }
  30. }
  31. else if ($obf_DT0kEiwCGj4WHj8fARUFXBQsORAfMgE->episode_type == 'link') {
  32. $array_filter = (object) ['post_id' => $post_id, 'link' => $episode_link, 'type' => $episode_type, 'subtitle' => $list_sub, 'sublabel' => $list_sub_label, 'sources' => ''];
  33. $obf_DSsIPlsCLTMYJA44Aj4OW1wOwouEzI = apply_filters('halim_type_filter', $array_filter);
  34.  
  35. if (has_filter('halim_type_filter')) {
  36. if ($obf_DSsIPlsCLTMYJA44Aj4OW1wOwouEzI->type == 'embed') {
  37. halim_detect_embed(['post_id' => $post_id, 'link' => $obf_DSsIPlsCLTMYJA44Aj4OW1wOwouEzI->link, 'subtitle' => $obf_DSsIPlsCLTMYJA44Aj4OW1wOwouEzI->subtitle, 'sublabel' => $obf_DSsIPlsCLTMYJA44Aj4OW1wOwouEzI->sublabel]);
  38. }
  39. else if ($obf_DSsIPlsCLTMYJA44Aj4OW1wOwouEzI->type == 'jwplayer') {
  40. $sources = $obf_DSsIPlsCLTMYJA44Aj4OW1wOwouEzI->sources;
  41. halimBuildPlayer($post_id, $sources, $tracks, $obf_DSsIPlsCLTMYJA44Aj4OW1wOwouEzI->link);
  42. }
  43. else {
  44. do_action('halim_custom_type_filter_sources', $array_filter);
  45. }
  46. }
  47. else {
  48. $sources = halim_detect_server($obf_DT0kEiwCGj4WHj8fARUFXBQsORAfMgE->link, $post_id)->sources;
  49. halimBuildPlayer($post_id, $sources, $tracks, $obf_DT0kEiwCGj4WHj8fARUFXBQsORAfMgE->link);
  50. }
  51. }
  52. else if ($obf_DT0kEiwCGj4WHj8fARUFXBQsORAfMgE->episode_type == 'mp4') {
  53. $result[] = ['file' => $obf_DT0kEiwCGj4WHj8fARUFXBQsORAfMgE->link, 'label' => 'FULL HD', 'type' => 'video/mp4'];
  54. $sources = json_encode($result);
  55. halimBuildPlayer($post_id, $sources, $tracks, $obf_DT0kEiwCGj4WHj8fARUFXBQsORAfMgE->link);
  56. }
  57. else if ($obf_DT0kEiwCGj4WHj8fARUFXBQsORAfMgE->episode_type == 'embed') {
  58. halim_detect_embed(['post_id' => $post_id, 'link' => $obf_DT0kEiwCGj4WHj8fARUFXBQsORAfMgE->link, 'subtitle' => $obf_DT0kEiwCGj4WHj8fARUFXBQsORAfMgE->subtitle, 'sublabel' => $obf_DT0kEiwCGj4WHj8fARUFXBQsORAfMgE->sublabel]);
  59. }
  60. else {
  61. echo '<div class="alert alert-danger text-center" role="alert">Episode Type "<strong>' . $obf_DT0kEiwCGj4WHj8fARUFXBQsORAfMgE->episode_type . '</strong>" chưa được hỗ trợ, vui lòng thiết lập API tùy chỉnh!</div>';
  62. }
  63. }
  64. else if ($episode_type == 'link') {
  65. $array_filter = (object) ['post_id' => $post_id, 'link' => $episode_link, 'type' => $episode_type, 'subtitle' => $list_sub, 'sublabel' => $list_sub_label, 'sources' => ''];
  66. $obf_DSsIPlsCLTMYJA44Aj4OW1wOwouEzI = apply_filters('halim_type_filter', $array_filter);
  67.  
  68. if (has_filter('halim_type_filter')) {
  69. if ($obf_DSsIPlsCLTMYJA44Aj4OW1wOwouEzI->type == 'embed') {
  70. halim_detect_embed(['post_id' => $post_id, 'link' => $obf_DSsIPlsCLTMYJA44Aj4OW1wOwouEzI->link, 'subtitle' => $obf_DSsIPlsCLTMYJA44Aj4OW1wOwouEzI->subtitle, 'sublabel' => $obf_DSsIPlsCLTMYJA44Aj4OW1wOwouEzI->sublabel]);
  71. }
  72. else if ($obf_DSsIPlsCLTMYJA44Aj4OW1wOwouEzI->type == 'jwplayer') {
  73. $sources = $obf_DSsIPlsCLTMYJA44Aj4OW1wOwouEzI->sources;
  74. halimBuildPlayer($post_id, $sources, $tracks, $obf_DSsIPlsCLTMYJA44Aj4OW1wOwouEzI->link);
  75. }
  76. else {
  77. do_action('halim_custom_type_filter_sources', $array_filter);
  78. }
  79. }
  80. else {
  81. $sources = halim_detect_server($episode_link, $post_id)->sources;
  82. halimBuildPlayer($post_id, $sources, $tracks, $episode_link);
  83. }
  84. }
  85. else if ($episode_type == 'mp4') {
  86. $result[] = ['file' => $episode_link, 'label' => 'FULL HD', 'type' => 'video/mp4'];
  87. $sources = json_encode($result);
  88. halimBuildPlayer($post_id, $sources, $tracks, $episode_link);
  89. }
  90. else if ($episode_type == 'embed') {
  91. halim_detect_embed(['post_id' => $post_id, 'link' => $episode_link, 'subtitle' => $list_sub, 'sublabel' => $list_sub_label]);
  92. }
  93. else {
  94. echo '<div class="alert alert-danger text-center" role="alert">Episode Type "<strong>' . $episode_type . '</strong>" chưa được hỗ trợ, vui lòng thiết lập API tùy chỉnh!</div>';
  95. }
  96. }
  97.  
  98. if (!function_exists('halim_detect_server')) {
  99. function halim_detect_server($link, $post_id)
  100. {
  101. $enable_cache = cs_get_option('player_cache');
  102. $cache_time = cs_get_option('player_cache_time');
  103. $cache = new Cache();
  104. $cache->timeCache = $cache_time;
  105. $getlink = new HALIM_GetLink();
  106. $getlink->init($link);
  107.  
  108. if ($enable_cache) {
  109. $cacheData = $cache->readCache($link);
  110.  
  111. .........................................................................
  112. ..........................................
  113. .................
Add Comment
Please, Sign In to add comment