lib1.php


SUBMITTED BY: kolaz

DATE: Jan. 22, 2016, 4:26 p.m.

FORMAT: PHP

SIZE: 26.9 kB

HITS: 309

  1. <?php
  2. class Wasato
  3. {
  4. public static function InitObj($_WICECAT_PRO_2_0_4_24_225FCDD350EC53C89DF81B798B87F668, $_WICECAT_PRO_2_0_4_24_099C5FBCE8B4D103E7ECBFDC02F95417)
  5. {
  6. foreach ($_WICECAT_PRO_2_0_4_24_099C5FBCE8B4D103E7ECBFDC02F95417 as $_WICECAT_PRO_2_0_4_24_8DFAC2739FDE4CD138C03ED864487CF8 => $_WICECAT_PRO_2_0_4_24_D5D1AB611B5C3261F9E0956257905AD8) {
  7. $_WICECAT_PRO_2_0_4_24_225FCDD350EC53C89DF81B798B87F668->$_WICECAT_PRO_2_0_4_24_8DFAC2739FDE4CD138C03ED864487CF8 = $_WICECAT_PRO_2_0_4_24_D5D1AB611B5C3261F9E0956257905AD8;
  8. }
  9. }
  10. function Wasato()
  11. {
  12. }
  13. public static function DemoMax($_WICECAT_PRO_2_0_4_24_5F3146DB24DEC06BCD086186BF93F54A)
  14. {
  15. switch ($_WICECAT_PRO_2_0_4_24_5F3146DB24DEC06BCD086186BF93F54A) {
  16. case 1:
  17. $_WICECAT_PRO_2_0_4_24_E86FF41F78624CAF1F631A0658197163 = 1000;
  18. break;
  19. case 2:
  20. $_WICECAT_PRO_2_0_4_24_E86FF41F78624CAF1F631A0658197163 = 1500;
  21. break;
  22. case 3:
  23. $_WICECAT_PRO_2_0_4_24_E86FF41F78624CAF1F631A0658197163 = 2000;
  24. break;
  25. case 4:
  26. $_WICECAT_PRO_2_0_4_24_E86FF41F78624CAF1F631A0658197163 = 2500;
  27. break;
  28. case 5:
  29. $_WICECAT_PRO_2_0_4_24_E86FF41F78624CAF1F631A0658197163 = 3000;
  30. break;
  31. case 6:
  32. $_WICECAT_PRO_2_0_4_24_E86FF41F78624CAF1F631A0658197163 = 3500;
  33. break;
  34. case 7:
  35. $_WICECAT_PRO_2_0_4_24_E86FF41F78624CAF1F631A0658197163 = 5000;
  36. break;
  37. case 8:
  38. $_WICECAT_PRO_2_0_4_24_E86FF41F78624CAF1F631A0658197163 = 7500;
  39. break;
  40. case 9:
  41. $_WICECAT_PRO_2_0_4_24_E86FF41F78624CAF1F631A0658197163 = 10000;
  42. break;
  43. default:
  44. $_WICECAT_PRO_2_0_4_24_E86FF41F78624CAF1F631A0658197163 = 500;
  45. break;
  46. }
  47. return $_WICECAT_PRO_2_0_4_24_E86FF41F78624CAF1F631A0658197163;
  48. }
  49. public static function AvailProducts($_WICECAT_PRO_2_0_4_24_34A76B26922C790F65C74EE82CC41A75)
  50. {
  51. $_WICECAT_PRO_2_0_4_24_F5564EE525ED0F31E1FD9D19A902EF52 = ' SELECT COUNT( `id_product` ) avail_products FROM `' . _DB_PREFIX_ . 'product` WHERE `id_icecat` >0 LIMIT ' . ($_WICECAT_PRO_2_0_4_24_34A76B26922C790F65C74EE82CC41A75 + 10);
  52. return Wql::Get($_WICECAT_PRO_2_0_4_24_F5564EE525ED0F31E1FD9D19A902EF52, true);
  53. }
  54. public static function ConfToken($_WICECAT_PRO_2_0_4_24_225FCDD350EC53C89DF81B798B87F668, $_WICECAT_PRO_2_0_4_24_4F952A11EEA566C3C291A9A404B4C53D = false)
  55. {
  56. if ($_WICECAT_PRO_2_0_4_24_4F952A11EEA566C3C291A9A404B4C53D === true) {
  57. return CodDec($_WICECAT_PRO_2_0_4_24_225FCDD350EC53C89DF81B798B87F668, 'wicecat');
  58. } else {
  59. $_WICECAT_PRO_2_0_4_24_225FCDD350EC53C89DF81B798B87F668->WsDat['avail_max'] = self::DemoMax($_WICECAT_PRO_2_0_4_24_225FCDD350EC53C89DF81B798B87F668->WsDat['control']);
  60. $_WICECAT_PRO_2_0_4_24_225FCDD350EC53C89DF81B798B87F668->WsDat['avail_text'] = $_WICECAT_PRO_2_0_4_24_225FCDD350EC53C89DF81B798B87F668->NFO6;
  61. $_WICECAT_PRO_2_0_4_24_225FCDD350EC53C89DF81B798B87F668->WsDat += self::AvailProducts($_WICECAT_PRO_2_0_4_24_225FCDD350EC53C89DF81B798B87F668->WsDat['avail_max']);
  62. return CodeEnc($_WICECAT_PRO_2_0_4_24_225FCDD350EC53C89DF81B798B87F668->WsDat, $_WICECAT_PRO_2_0_4_24_225FCDD350EC53C89DF81B798B87F668->name);
  63. }
  64. }
  65. public static function ConfData($_WICECAT_PRO_2_0_4_24_01A4727417E0A54CE9922E716B70FD59)
  66. {
  67. if (empty($_WICECAT_PRO_2_0_4_24_01A4727417E0A54CE9922E716B70FD59['DATA']['TOKEN'])) {
  68. die('NO-DATA');
  69. }
  70. $_WICECAT_PRO_2_0_4_24_E2AAC8AD36937842CC909B890E90AAA9 = Wasato::ConfToken($_POST['DATA']['TOKEN'], true);
  71. if (empty($_WICECAT_PRO_2_0_4_24_E2AAC8AD36937842CC909B890E90AAA9))
  72. die('NO-LICENSE');
  73. if ((int) $_WICECAT_PRO_2_0_4_24_E2AAC8AD36937842CC909B890E90AAA9['promotion'] === 1) {
  74. if ((int) $_WICECAT_PRO_2_0_4_24_E2AAC8AD36937842CC909B890E90AAA9['avail_products'] >= (int) $_WICECAT_PRO_2_0_4_24_E2AAC8AD36937842CC909B890E90AAA9['avail_max'])
  75. die($_WICECAT_PRO_2_0_4_24_E2AAC8AD36937842CC909B890E90AAA9['avail_text']);
  76. $_WICECAT_PRO_2_0_4_24_E971BCC5079F2558274693F15C19EF7C = self::AvailProducts($_WICECAT_PRO_2_0_4_24_E2AAC8AD36937842CC909B890E90AAA9['avail_max']);
  77. if ($_WICECAT_PRO_2_0_4_24_E971BCC5079F2558274693F15C19EF7C['avail_products'] >= (int) $_WICECAT_PRO_2_0_4_24_E2AAC8AD36937842CC909B890E90AAA9['avail_max'])
  78. die($_WICECAT_PRO_2_0_4_24_E2AAC8AD36937842CC909B890E90AAA9['avail_text']);
  79. }
  80. return $_WICECAT_PRO_2_0_4_24_01A4727417E0A54CE9922E716B70FD59;
  81. }
  82. public static function VerData($_WICECAT_PRO_2_0_4_24_225FCDD350EC53C89DF81B798B87F668)
  83. {
  84. if ((int) $_WICECAT_PRO_2_0_4_24_225FCDD350EC53C89DF81B798B87F668->WsDat['avail_products'] >= (int) $_WICECAT_PRO_2_0_4_24_225FCDD350EC53C89DF81B798B87F668->WsDat['avail_max'])
  85. return true;
  86. return false;
  87. }
  88. public static function ConfValues($_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17)
  89. {
  90. return array(
  91. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NameUpper . '_EULA' => 'false',
  92. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NameUpper . '_LICENSE' => 'false',
  93. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NameUpper . '_CODE' => '' . $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->ModuleCode . '',
  94. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NameUpper . '_NAME' => '' . $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->ModuleName . '',
  95. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NameUpper . '_ID' => '' . $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->ModuleID . '',
  96. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NameUpper . '_WIZARD' => 'false',
  97. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NameUpper . '_VERSION' => '' . $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->version . '',
  98. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NameUpper . '_ICECAT_USER' => null,
  99. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NameUpper . '_ICECAT_PASS' => null,
  100. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NameUpper . '_ICECAT_TYPE' => null,
  101. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NameUpper . '_TIMER' => '120',
  102. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NameUpper . '_CATEGORY_AUTOUPD' => 'true',
  103. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NameUpper . '_MAX_PRODS' => '5000',
  104. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NameUpper . '_CSV_1' => 'false',
  105. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NameUpper . '_CSV_2' => 'false',
  106. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NameUpper . '_CSV_3' => 'false',
  107. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NameUpper . '_CAT_LIST' => 'false',
  108. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NameUpper . '_LIMIT_SEARCH' => '10',
  109. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NameUpper . '_COMPLETE_FILE' => 'false',
  110. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NameUpper . '_CRON_SET' => CronToken(),
  111. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NameUpper . '_RELATE_AUTO' => 'true',
  112. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NameUpper . '_LDESC_SUM' => 'false',
  113. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NameUpper . '_ICECAT_ERROR' => 'false',
  114. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NameUpper . '_PRODS_WEIGHT' => 'false',
  115. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NameUpper . '_MANU_LOGO' => 'true',
  116. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NameUpper . '_PRODS_ACTIVE' => 'true',
  117. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NameUpper . '_SEO_CHARS' => 'false',
  118. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NameUpper . '_IMAGE_UPDATE' => 'false',
  119. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NameUpper . '_IMAGE_ORIGINAL' => 'false',
  120. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NameUpper . '_STOCK_UPDATE' => 'false',
  121. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NameUpper . '_FEATS_FILTERS' => 'false',
  122. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NameUpper . '_ENABLD_CATS' => 'false',
  123. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NameUpper . '_ENABLD_MANU' => 'false',
  124. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NameUpper . '_UPD_PRREF' => 'false',
  125. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NameUpper . '_LIST_OPEN' => 'false',
  126. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NameUpper . '_SHOW_TABLE' => 'true',
  127. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NameUpper . '_SHOW_MLTM' => 'true',
  128. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NameUpper . '_SHOW_LOGS' => 'true',
  129. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NameUpper . '_SHOW_WRRNT' => 'true',
  130. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NameUpper . '_SHOW_YNLOG' => 'true',
  131. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NameUpper . '_SHOW_SOURCE' => 'false',
  132. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NameUpper . '_FEATS_ID' => isVersion('1.6') ? '.table-data-sheet' : '#idTab2',
  133. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NameUpper . '_HOME_CAT' => HomeCat()
  134. );
  135. }
  136. private static function ShowContent($_WICECAT_PRO_2_0_4_24_225FCDD350EC53C89DF81B798B87F668)
  137. {
  138. if (file_exists(dirname(__FILE__) . '/../views/view.php')) {
  139. include_once(dirname(__FILE__) . '/../views/view.php');
  140. return MainContent::display($_WICECAT_PRO_2_0_4_24_225FCDD350EC53C89DF81B798B87F668);
  141. }
  142. }
  143. public static function ModuleContent($myModule)
  144. {
  145. if (time() < intval($myModule->WsDat['license_end']))
  146. {
  147. $_WICECAT_PRO_2_0_4_24_80B015E946EFC2C404F3E5B325C4B851 = $myModule->mod_content;
  148. $_WICECAT_PRO_2_0_4_24_513E28F68AA618A57D5E9AB47C5A4CE1 = ReadLicense();
  149. if (self::SetHash($myModule, $_WICECAT_PRO_2_0_4_24_513E28F68AA618A57D5E9AB47C5A4CE1) === $myModule->WsDat['hash'])
  150. {
  151. return self::ShowContent($myModule);
  152. } elseif ($myModule->ModuleCode != $myModule->WsDat['module_code'])
  153. return $_WICECAT_PRO_2_0_4_24_80B015E946EFC2C404F3E5B325C4B851::ShowERRORMOD($myModule, $myModule->WrongModuleCode, $myModule->WrongModuleInfo);
  154. elseif ($myModule->ModuleName != $myModule->WsDat['module_name'])
  155. return $_WICECAT_PRO_2_0_4_24_80B015E946EFC2C404F3E5B325C4B851::ShowERRORMOD($myModule, $myModule->WrongModule, $myModule->WrongModuleInfo);
  156. elseif ($_WICECAT_PRO_2_0_4_24_513E28F68AA618A57D5E9AB47C5A4CE1['transacion'] != $myModule->WsDat['purchase_number'])
  157. return $_WICECAT_PRO_2_0_4_24_80B015E946EFC2C404F3E5B325C4B851::ShowERRORMOD($myModule, $myModule->WrongModuleCode, $myModule->WrongModuleInfo);
  158. elseif (md5(trim($_WICECAT_PRO_2_0_4_24_513E28F68AA618A57D5E9AB47C5A4CE1['license'])) != md5(trim($myModule->WsDat['license'])))
  159. return $_WICECAT_PRO_2_0_4_24_80B015E946EFC2C404F3E5B325C4B851::ShowERRORMOD($myModule, $myModule->WrongLicense, $myModule->WrongLicenseInfo);
  160. elseif (($myModule->Domain != $myModule->WsDat['domain']) || ($_WICECAT_PRO_2_0_4_24_513E28F68AA618A57D5E9AB47C5A4CE1['domain'] != $myModule->Domain))
  161. return $_WICECAT_PRO_2_0_4_24_80B015E946EFC2C404F3E5B325C4B851::ShowERRORMOD($myModule, $myModule->WrongDomian, $myModule->WrongDomianInfo);
  162. elseif (($myModule->IP != $myModule->WsDat['ip_client']) || ($_WICECAT_PRO_2_0_4_24_513E28F68AA618A57D5E9AB47C5A4CE1['ip'] != $myModule->IP))
  163. return $_WICECAT_PRO_2_0_4_24_80B015E946EFC2C404F3E5B325C4B851::ShowERRORMOD($myModule, $myModule->NoIP, $myModule->NoIPInfo);
  164. else
  165. return $_WICECAT_PRO_2_0_4_24_80B015E946EFC2C404F3E5B325C4B851::ShowERRORMOD($myModule, $myModule->InvalidLicense, $myModule->NoLicensefile);
  166. } else
  167. return $_WICECAT_PRO_2_0_4_24_80B015E946EFC2C404F3E5B325C4B851::ShowERRORMOD($myModule, $myModule->ExpiredLicense, $myModule->ExpiredLicenseInfo);
  168. }
  169. public static function banner($_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17)
  170. {
  171. if (file_exists(dirname(__FILE__) . '/../class/class2.php')) {
  172. include_once(dirname(__FILE__) . '/../class/class2.php');
  173. return Banner::display($_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17);
  174. }
  175. }
  176. public function InstallWasatoModule($_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17)
  177. {
  178. if (file_exists(dirname(__FILE__) . '/../class/class3.php')) {
  179. include_once(dirname(__FILE__) . '/../class/class3.php');
  180. if (!InstallModule::Install($_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17))
  181. return false;
  182. }
  183. return true;
  184. }
  185. public static function UninstallWasatoModule($_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17)
  186. {
  187. if (!file_exists(dirname(__FILE__) . '/../class/class3.php'))
  188. return false;
  189. include_once(dirname(__FILE__) . '/../class/class3.php');
  190. if (!InstallModule::Uninstall($_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17))
  191. return false;
  192. return true;
  193. }
  194. public static function UpgradeWModule($_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17)
  195. {
  196. if (!file_exists(dirname(__FILE__) . '/../class/class3.php'))
  197. return $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->Info;
  198. include_once(dirname(__FILE__) . '/../class/class3.php');
  199. if ($_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->Info[$_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NAME . '_VERSION'] < $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->version) {
  200. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->Info = InstallModule::Upgrade($_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17);
  201. } else {
  202. $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->Info[$_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NAME . '_UPGRADE'] = false;
  203. }
  204. return $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->Info;
  205. }
  206. public static function GetDwnLink($_WICECAT_PRO_2_0_4_24_225FCDD350EC53C89DF81B798B87F668)
  207. {
  208. $_WICECAT_PRO_2_0_4_24_F146E0A98147190859482237B10CC796 = ReadLicense();
  209. $_WICECAT_PRO_2_0_4_24_00923E09EBAD46E73C33A9CAE859345E = empty($_WICECAT_PRO_2_0_4_24_F146E0A98147190859482237B10CC796['purchase_number']) ? (empty($_WICECAT_PRO_2_0_4_24_F146E0A98147190859482237B10CC796['transacion']) ? null : $_WICECAT_PRO_2_0_4_24_F146E0A98147190859482237B10CC796['transacion']) : $_WICECAT_PRO_2_0_4_24_F146E0A98147190859482237B10CC796['purchase_number'];
  210. return 'http://wasato.com/download.php?Token=' . $_WICECAT_PRO_2_0_4_24_225FCDD350EC53C89DF81B798B87F668->ModuleToken . '&Code=' . $_WICECAT_PRO_2_0_4_24_00923E09EBAD46E73C33A9CAE859345E;
  211. }
  212. public static function GetCronLink($_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17)
  213. {
  214. $_WICECAT_PRO_2_0_4_24_36C7C23B8009311D015CE2FE806CCCDE = Wasato::GetHttp($_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->name) . __PS_BASE_URI__ . 'modules/';
  215. $_WICECAT_PRO_2_0_4_24_36C7C23B8009311D015CE2FE806CCCDE .= $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->name . '/utils/cron.php?ExeCRON=' . $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->Info[$_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->NAME . '_CRON_SET'];
  216. return $_WICECAT_PRO_2_0_4_24_36C7C23B8009311D015CE2FE806CCCDE;
  217. }
  218. public static function GetHttp($_WICECAT_PRO_2_0_4_24_8927FF3AA25CCE62FBCB673BB3C6883A)
  219. {
  220. $_WICECAT_PRO_2_0_4_24_8927FF3AA25CCE62FBCB673BB3C6883A = strtolower($_WICECAT_PRO_2_0_4_24_8927FF3AA25CCE62FBCB673BB3C6883A);
  221. if (self::SecureHost())
  222. $_WICECAT_PRO_2_0_4_24_27E13D3A6673BB0F53FAAA8C107A3565 = 'https://';
  223. else
  224. $_WICECAT_PRO_2_0_4_24_27E13D3A6673BB0F53FAAA8C107A3565 = 'http://';
  225. return $_WICECAT_PRO_2_0_4_24_27E13D3A6673BB0F53FAAA8C107A3565 . $_SERVER['HTTP_HOST'];
  226. }
  227. private static function SecureHost()
  228. {
  229. if (isset($_SERVER['HTTPS']))
  230. return ($_SERVER['HTTPS'] == 1 || strtolower($_SERVER['HTTPS']) == 'on');
  231. if (isset($_SERVER['SSL']))
  232. return ($_SERVER['SSL'] == 1 || strtolower($_SERVER['SSL']) == 'on');
  233. return false;
  234. }
  235. public static function SetHash($_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17, $_WICECAT_PRO_2_0_4_24_F146E0A98147190859482237B10CC796)
  236. {
  237. $_WICECAT_PRO_2_0_4_24_089BBBDDCCB55F27D1EF90A298058334 = $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->ModuleCode;
  238. $_WICECAT_PRO_2_0_4_24_089BBBDDCCB55F27D1EF90A298058334 .= $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->ModuleName;
  239. $_WICECAT_PRO_2_0_4_24_089BBBDDCCB55F27D1EF90A298058334 .= $_WICECAT_PRO_2_0_4_24_F146E0A98147190859482237B10CC796['transacion'];
  240. $_WICECAT_PRO_2_0_4_24_089BBBDDCCB55F27D1EF90A298058334 .= $_WICECAT_PRO_2_0_4_24_F146E0A98147190859482237B10CC796['license'];
  241. $_WICECAT_PRO_2_0_4_24_089BBBDDCCB55F27D1EF90A298058334 .= ($_WICECAT_PRO_2_0_4_24_F146E0A98147190859482237B10CC796['domain'] === $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->Domain ? $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->Domain : $_WICECAT_PRO_2_0_4_24_F146E0A98147190859482237B10CC796['domain']);
  242. $_WICECAT_PRO_2_0_4_24_089BBBDDCCB55F27D1EF90A298058334 .= ($_WICECAT_PRO_2_0_4_24_F146E0A98147190859482237B10CC796['ip'] === $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->IP ? $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->IP : $_WICECAT_PRO_2_0_4_24_F146E0A98147190859482237B10CC796['ip']);
  243. return md5($_WICECAT_PRO_2_0_4_24_089BBBDDCCB55F27D1EF90A298058334);
  244. }
  245. public static function Trace($_WICECAT_PRO_2_0_4_24_97855EF3D970439C1AF506E018173B37, $_WICECAT_PRO_2_0_4_24_0AD2703D397087F50AD2EA8839D70663 = false, $_WICECAT_PRO_2_0_4_24_F4F1F138D8D4E48579447A2EE754DB6D = 'MySQL')
  246. {
  247. if (!empty($_WICECAT_PRO_2_0_4_24_97855EF3D970439C1AF506E018173B37)) {
  248. $_WICECAT_PRO_2_0_4_24_1465A2DCF83DABD39860F697C14810B8 = 1;
  249. $_WICECAT_PRO_2_0_4_24_3978D7858AA530ECC07F2DBE3DABF57A = "\r\n\t" . $_WICECAT_PRO_2_0_4_24_F4F1F138D8D4E48579447A2EE754DB6D . ' Stack trace:' . "\r\n";
  250. foreach ($_WICECAT_PRO_2_0_4_24_97855EF3D970439C1AF506E018173B37 as $_WICECAT_PRO_2_0_4_24_E202ADB9BB70BFFBAB589EE0E166A607) {
  251. if (count($_WICECAT_PRO_2_0_4_24_97855EF3D970439C1AF506E018173B37) === $_WICECAT_PRO_2_0_4_24_1465A2DCF83DABD39860F697C14810B8) {
  252. $_WICECAT_PRO_2_0_4_24_4B58F68ED81B2B718ACD0A99E685CEFA = $_WICECAT_PRO_2_0_4_24_0AD2703D397087F50AD2EA8839D70663 . "\t" . '- On line: "' . $_WICECAT_PRO_2_0_4_24_E202ADB9BB70BFFBAB589EE0E166A607['line'] . '"' . "\r\n";
  253. $_WICECAT_PRO_2_0_4_24_4B58F68ED81B2B718ACD0A99E685CEFA .= "\t" . '- From file: ' . $_WICECAT_PRO_2_0_4_24_E202ADB9BB70BFFBAB589EE0E166A607['file'] . "\r\n";
  254. } elseif ($_WICECAT_PRO_2_0_4_24_1465A2DCF83DABD39860F697C14810B8 === 1)
  255. $_WICECAT_PRO_2_0_4_24_3978D7858AA530ECC07F2DBE3DABF57A .= "\t" . $_WICECAT_PRO_2_0_4_24_1465A2DCF83DABD39860F697C14810B8 . '.- "' . $_WICECAT_PRO_2_0_4_24_E202ADB9BB70BFFBAB589EE0E166A607['line'] . '" {main}() ' . $_WICECAT_PRO_2_0_4_24_E202ADB9BB70BFFBAB589EE0E166A607['file'] . "\r\n";
  256. else {
  257. $_WICECAT_PRO_2_0_4_24_5F864AE10426358580F6F88B4DD5096A = empty($_WICECAT_PRO_2_0_4_24_E202ADB9BB70BFFBAB589EE0E166A607['class']) ? '' : $_WICECAT_PRO_2_0_4_24_E202ADB9BB70BFFBAB589EE0E166A607['class'];
  258. $_WICECAT_PRO_2_0_4_24_831024F2EABD3DDA5814913C524C0C25 = empty($_WICECAT_PRO_2_0_4_24_E202ADB9BB70BFFBAB589EE0E166A607['type']) ? '' : $_WICECAT_PRO_2_0_4_24_E202ADB9BB70BFFBAB589EE0E166A607['type'];
  259. $_WICECAT_PRO_2_0_4_24_A917A7D71449B52B8B86A6AC20DFF899 = $_WICECAT_PRO_2_0_4_24_5F864AE10426358580F6F88B4DD5096A . '' . $_WICECAT_PRO_2_0_4_24_831024F2EABD3DDA5814913C524C0C25 . '' . $_WICECAT_PRO_2_0_4_24_E202ADB9BB70BFFBAB589EE0E166A607['function'];
  260. $_WICECAT_PRO_2_0_4_24_3978D7858AA530ECC07F2DBE3DABF57A .= "\t" . $_WICECAT_PRO_2_0_4_24_1465A2DCF83DABD39860F697C14810B8 . '.- "' . $_WICECAT_PRO_2_0_4_24_E202ADB9BB70BFFBAB589EE0E166A607['line'] . '" ' . $_WICECAT_PRO_2_0_4_24_A917A7D71449B52B8B86A6AC20DFF899 . '() ' . $_WICECAT_PRO_2_0_4_24_E202ADB9BB70BFFBAB589EE0E166A607['file'] . "\r\n";
  261. }
  262. $_WICECAT_PRO_2_0_4_24_1465A2DCF83DABD39860F697C14810B8++;
  263. }
  264. return $_WICECAT_PRO_2_0_4_24_4B58F68ED81B2B718ACD0A99E685CEFA . '' . $_WICECAT_PRO_2_0_4_24_3978D7858AA530ECC07F2DBE3DABF57A;
  265. } else
  266. return false;
  267. }
  268. public static function SetLog($_WICECAT_PRO_2_0_4_24_5E4960089B7CC58686EA7F2EAECCB698)
  269. {
  270. if (empty($_WICECAT_PRO_2_0_4_24_5E4960089B7CC58686EA7F2EAECCB698))
  271. return false;
  272. $_WICECAT_PRO_2_0_4_24_11D7662F51CCACDA97C20C9C9365FC80 = dirname(__FILE__) . '/../logs/error_log.txt';
  273. $_WICECAT_PRO_2_0_4_24_1F2771B9616DE90EBFBA20B7117090C1 = fopen($_WICECAT_PRO_2_0_4_24_11D7662F51CCACDA97C20C9C9365FC80, 'a');
  274. if ($_WICECAT_PRO_2_0_4_24_1F2771B9616DE90EBFBA20B7117090C1) {
  275. fwrite($_WICECAT_PRO_2_0_4_24_1F2771B9616DE90EBFBA20B7117090C1, $_WICECAT_PRO_2_0_4_24_5E4960089B7CC58686EA7F2EAECCB698);
  276. fclose(($_WICECAT_PRO_2_0_4_24_1F2771B9616DE90EBFBA20B7117090C1));
  277. return true;
  278. } else
  279. return false;
  280. }
  281. public static function ShowPaginationOptions($_WICECAT_PRO_2_0_4_24_0C674EA587CF07FD8B3977C455047E4F, $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17)
  282. {
  283. $_WICECAT_PRO_2_0_4_24_27E13D3A6673BB0F53FAAA8C107A3565 = ' <div id=\'' . $_WICECAT_PRO_2_0_4_24_0C674EA587CF07FD8B3977C455047E4F . '_pages\' class=\'products_pages\'> <ul> <li> <input id=\'' . $_WICECAT_PRO_2_0_4_24_0C674EA587CF07FD8B3977C455047E4F . '_pages_begin\' class=\'pages_buttons\' ctr=\'0\' type="submit" title=\'' . $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->Beginning . '\' value=\'<<\' name=\'' . $_WICECAT_PRO_2_0_4_24_0C674EA587CF07FD8B3977C455047E4F . '\'> </li> <li> <input id=\'' . $_WICECAT_PRO_2_0_4_24_0C674EA587CF07FD8B3977C455047E4F . '_pages_previous\' class=\'pages_button\' ctr=\'0\' type="submit" title=\'' . $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->Previous . '\' value="<" name=\'' . $_WICECAT_PRO_2_0_4_24_0C674EA587CF07FD8B3977C455047E4F . '\'> </li> <li> ' . $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->PageN . ': <select id=\'' . $_WICECAT_PRO_2_0_4_24_0C674EA587CF07FD8B3977C455047E4F . '_pages_current\' ctr=\'0\' class=\'pages_select\' name=\'' . $_WICECAT_PRO_2_0_4_24_0C674EA587CF07FD8B3977C455047E4F . '\' ></select> </li> <li> <input id=\'' . $_WICECAT_PRO_2_0_4_24_0C674EA587CF07FD8B3977C455047E4F . '_pages_next\' class=\'pages_button\' ctr=\'0\' type="submit" title=\'' . $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->Next . '\' value=">" name=\'' . $_WICECAT_PRO_2_0_4_24_0C674EA587CF07FD8B3977C455047E4F . '\' > </li> <li> <input id=\'' . $_WICECAT_PRO_2_0_4_24_0C674EA587CF07FD8B3977C455047E4F . '_pages_end\' class=\'pages_buttons\' ctr=\'0\' type="submit" title=\'' . $_WICECAT_PRO_2_0_4_24_CD1B10D1DF4B2C9CB4C870C2C68D7D17->End . '\' value=">>" name=\'' . $_WICECAT_PRO_2_0_4_24_0C674EA587CF07FD8B3977C455047E4F . '\' > </li> </ul> </div> ';
  284. return $_WICECAT_PRO_2_0_4_24_27E13D3A6673BB0F53FAAA8C107A3565;
  285. }
  286. public static function GetDefaultLangs()
  287. {
  288. return Wql::Get('SELECT `T1`.`iso_code`, `T1`.`id_lang` FROM `' . _DB_PREFIX_ . 'lang` AS T1 INNER JOIN `' . _DB_PREFIX_ . 'configuration` AS T2 ON `T1`.`id_lang` = `T2`.`value` WHERE `T2`.`name` = \'PS_LANG_DEFAULT\'');
  289. }
  290. public static function Langs()
  291. {
  292. return Wql::Get('SELECT * FROM `' . _DB_PREFIX_ . 'lang`');
  293. }
  294. public static function GetDefautlCountry()
  295. {
  296. return strtolower(Wql::GetVal('SELECT DISTINCT T2.`iso_code` FROM `' . _DB_PREFIX_ . 'configuration` AS T1 INNER JOIN `' . _DB_PREFIX_ . 'country` AS T2 ON T1.`value` = T2.`id_country` WHERE T1.name = \'PS_COUNTRY_DEFAULT\' '));
  297. }
  298. public static function GetDefaultCurrency()
  299. {
  300. return Wql::GetVal('SELECT `T1`.`iso_code` FROM `' . _DB_PREFIX_ . 'currency` AS T1 INNER JOIN `' . _DB_PREFIX_ . 'configuration` AS T2 ON `T1`.`id_currency` = `T2`.`value` WHERE `T2`.`name` = \'PS_CURRENCY_DEFAULT\'');
  301. }
  302. public static function GetImageType()
  303. {
  304. return Wql::Get(' SELECT * FROM `' . _DB_PREFIX_ . 'image_type` WHERE `products` = \'1\' ');
  305. }
  306. public static function GetSeo()
  307. {
  308. $_WICECAT_PRO_2_0_4_24_F5564EE525ED0F31E1FD9D19A902EF52 = 'SHOW TABLES LIKE \'' . _DB_PREFIX_ . 'wasato_category_keywords_lang\' ';
  309. if (Wql::Get($_WICECAT_PRO_2_0_4_24_F5564EE525ED0F31E1FD9D19A902EF52)) {
  310. $_WICECAT_PRO_2_0_4_24_A54412920D9FD34383EB3470F8999E6C = Wql::Get(' SELECT COUNT(*) AS total FROM `' . _DB_PREFIX_ . 'wasato_category_keywords_lang` LIMIT 10 ');
  311. return $_WICECAT_PRO_2_0_4_24_A54412920D9FD34383EB3470F8999E6C[0]['total'];
  312. } else
  313. return 0;
  314. }
  315. }

comments powered by Disqus