Guest User

Untitled

a guest
Oct 16th, 2020
13
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  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 get_base_url()
  15. {
  16. if (!empty($_SERVER['HTTPS'])) {
  17. return 'https://' . str_replace('www.', '', $_SERVER['HTTP_HOST']);
  18. }
  19. else {
  20. return 'http://' . str_replace('www.', '', $_SERVER['HTTP_HOST']);
  21. }
  22. }
  23.  
  24. function uniq_key()
  25. {
  26. return md5(get_base_url());
  27. }
  28.  
  29. function clr_url()
  30. {
  31. return hash('sha1', md5(base64_decode(rtrim(str_replace(['http://', 'https://', 'www.'], ['', '', ''], get_base_url()), '/'))) . getSiteAdi());
  32. }
  33.  
  34. function license_check()
  35. {
  36. global $baglan;
  37. global $db;
  38. if (!isset($baglan) && !isset($db)) {
  39. exit('Bağlan bulunamadı!');
  40. }
  41.  
  42. $lk = clr_url();
  43.  
  44. if (isset($baglan)) {
  45. $license = mysql_query('SELECT * FROM lisans WHERE kod = \'' . $lk . '\'');
  46.  
  47. if (mysql_num_rows($license) == 0) {
  48. require_once 'lisans.php';
  49. exit('');
  50. }
  51. }
  52. else {
  53. $xlm = $db->prepare('SELECT * FROM lisans WHERE kod = ? ');
  54. $xlm->execute([$lk]);
  55. $xml = $xlm->fetch(PDO::FETCH_ASSOC);
  56.  
  57. if (!$xml) {
  58. require_once 'lisans.php';
  59. exit('');
  60. }
  61. }
  62.  
  63. return true;
  64. }
  65.  
  66. function remove_all()
  67. {
  68. global $baglan;
  69. global $db;
  70.  
  71. if (isset($baglan)) {
  72. mysql_query('DELETE FROM lisans WHERE 1');
  73. mysql_query('DROP TABLE IF EXIST lisans');
  74. }
  75.  
  76. if (isset($db)) {
  77. $db->query('DELETE FROM lisans WHERE 1')->fetch();
  78. $db->query('DROP TABLE IF EXIST lisans')->fetch();
  79. }
  80.  
  81. return license_check();
  82. }
  83.  
  84. function aktif($urlsi)
  85. {
  86. $mesaj = '';
  87. $url = 'http://' . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI'];
  88.  
  89. if (strpos($url, $urlsi) !== false) {
  90. $mesaj = 'active';
  91. }
  92.  
  93. return $mesaj;
  94. }
  95.  
  96. function AktifLink($urlsi)
  97. {
  98. $aktif = '';
  99.  
  100. if (strstr($_SERVER[HTTP_HOST] . '/' . $_SERVER[REQUEST_URI], $urlsi)) {
  101. $aktif = 'act-link';
  102. }
  103.  
  104. return $aktif;
  105. }
  106.  
  107. function kdv_fiyat($urun_fiyat, $urun_kdv)
  108. {
  109. $toplam = $urun_fiyat * ($urun_kdv / 100);
  110. return $toplam;
  111. }
  112.  
  113. function kdval($urun_fiyat, $urun_kdv)
  114. {
  115. $toplam = $urun_fiyat + ($urun_fiyat * ($urun_kdv / 100));
  116. return $toplam;
  117. }
  118.  
  119. function format_size($size)
  120. {
  121. $sizes = [' Bytes', ' KB', ' MB', ' GB', ' TB', ' PB', ' EB', ' ZB', ' YB'];
  122.  
  123. if ($size == 0) {
  124. return 'n/a';
  125. }
  126. else {
  127. return round($size / pow(1024, $i = floor(log($size, 1024))), 2) . $sizes[$i];
  128. }
  129. }
  130.  
  131. function ip()
  132. {
  133. if (getenv('HTTP_CLIENT_IP')) {
  134. $ip = getenv('HTTP_CLIENT_IP');
  135. }
  136. else if (getenv('HTTP_X_FORWARDED_FOR')) {
  137. $ip = getenv('HTTP_X_FORWARDED_FOR');
  138.  
  139. if (strstr($ip, ',')) {
  140. $tmp = explode(',', $ip);
  141. $ip = trim($tmp[0]);
  142. }
  143. }
  144. else {
  145. $ip = getenv('REMOTE_ADDR');
  146. }
  147.  
  148. return $ip;
  149. }
  150.  
  151. function kod($uzunluk = 8, $buyuk_harf = 1, $kucuk_harf = 1, $sayi_kullan = 1, $ozel_karakter = '')
  152. {
  153. $buyukler = 'ABCDEFGHIJKLMNOPQRSTUVWXYZ';
  154. $kucukler = 'abcdefghijklmnopqrstuvwxyz';
  155. $sayilar = '0123456789';
  156.  
  157. if ($buyuk_harf) {
  158. $seed_length += 26;
  159. $seed .= $buyukler;
  160. }
  161.  
  162. if ($kucuk_harf) {
  163. $seed_length += 26;
  164. $seed .= $kucukler;
  165. }
  166.  
  167. if ($sayi_kullan) {
  168. $seed_length += 10;
  169. $seed .= $sayilar;
  170. }
  171.  
  172. if ($ozel_karakter) {
  173. $seed_length += strlen($ozel_karakter);
  174. $seed .= $ozel_karakter;
  175. }
  176.  
  177. for ($x = 1; $x <= $uzunluk; $x++) {
  178. $sifre .= $seed[rand(0, $seed_length - 1)];
  179. }
  180.  
  181. return $sifre;
  182. }
  183.  
  184. function seoyap($s)
  185. {
  186. $tr = ['ş', 'Ş', 'ı', 'İ', 'ğ', 'Ğ', 'ü', 'Ü', 'ö', 'Ö', 'ç', 'Ç'];
  187. $en = ['s', 's', 'i', 'i', 'g', 'g', 'u', 'u', 'o', 'o', 'c', 'c'];
  188. $s = str_replace($tr, $en, $s);
  189. $s = strtolower($s);
  190. $s = preg_replace('/&amp;amp;amp;amp;amp;amp;amp;amp;.+?;/', '-', $s);
  191. $s = preg_replace('/[^%a-z0-9 _-]/', '-', $s);
  192. $s = preg_replace('/\\s+/', '-', $s);
  193. $s = preg_replace('|-+|', '-', $s);
  194. $s = str_replace('--', '-', $s);
  195. $s = trim($s, '-');
  196. return $s;
  197. }
  198.  
  199. function kisalt($metin, $uzunluk = 50)
  200. {
  201. if ($uzunluk < strlen($metin)) {
  202. $metin = substr($metin, 0, $uzunluk) . '...';
  203. $metin_son = strrchr($metin, ' ');
  204. $metin = str_replace($metin_son, ' ...', $metin);
  205. }
  206.  
  207. return $metin;
  208. }
  209.  
  210. function NumaraDuzelt($gelendata)
  211. {
  212. $deger1 = ['(', ')', ' '];
  213. $deger2 = ['', '', ''];
  214. $degismishali = str_replace($deger1, $deger2, $gelendata);
  215. return $degismishali;
  216. }
  217.  
  218. function tarih($par)
  219. {
  220. $explode = explode(' ', $par);
  221. $explode2 = explode('-', $explode[0]);
  222. $zaman = substr($explode[1], 0, 5);
  223.  
  224. if ($explode2[1] == '01') {
  225. $ay = 'Ocak';
  226. }
  227. else if ($explode2[1] == '02') {
  228. $ay = 'Şubat';
  229. }
  230. else if ($explode2[1] == '03') {
  231. $ay = 'Mart';
  232. }
  233. else if ($explode2[1] == '04') {
  234. $ay = 'Nisan';
  235. .............................................................................
  236. ...........................................
  237. .........................
RAW Paste Data