Your project uses non-strict array lookups 288

More information: https://insight.symfony.com/what-we-analyse/php.strict_array_lookup

  1. exit;
  2. }
  3. // Validate feedback_type
  4. $validTypes = ['positive', 'negative', 'correction'];
  5. if (!in_array($input['feedback_type'], $validTypes)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. echo json_encode([
  7. 'success' => false,
  8. 'error' => 'feedback_type must be one of: ' . implode(', ', $validTypes)
  9. ]);
  10. exit;
  1. $errors = [];
  2. // ============================================================================
  3. // 1. Reset Translation Cache
  4. // ============================================================================
  5. if (in_array('translations', $cacheTypes)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. try {
  7. $translationCache = new TranslationCache();
  8. // Count files before
  9. $cacheDir = CLICSHOPPING::getConfig('dir_root', 'Shop') . 'Work/Cache/Rag/Translation/';
  1. }
  2. // ============================================================================
  3. // 3. Reset Classification Cache
  4. // ============================================================================
  5. if (in_array('classification', $cacheTypes)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. try {
  7. $classificationCache = new ClassificationCache();
  8. // Get stats before
  9. $statsBefore = $classificationCache->getStatistics();
  1. }
  2. // ============================================================================
  3. // 3. Reset Database Query Cache
  4. // ============================================================================
  5. if (in_array('database', $cacheTypes)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. try {
  7. $db = Registry::get('Db');
  8. $prefix = CLICSHOPPING::getConfig('db_table_prefix');
  9. // Count entries before
  1. }
  2. // ============================================================================
  3. // 4. Reset Schema Query Cache (TASK 5 - ITEM 1)
  4. // ============================================================================
  5. if (in_array('schema', $cacheTypes)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. try {
  7. // Count schema cache files before (new location)
  8. $schemaCacheDir = CLICSHOPPING::getConfig('dir_root', 'Shop') . 'Work/Cache/Rag/SchemaQuery/';
  9. $filesBefore = 0;
  1. }
  2. // ============================================================================
  3. // 5. Reset Intent Classification Cache (TASK 5.1.7.6)
  4. // ============================================================================
  5. if (in_array('intent', $cacheTypes)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. try {
  7. // Count intent cache files before (new location - all files)
  8. $intentCacheDir = CLICSHOPPING::getConfig('dir_root', 'Shop') . 'Work/Cache/Rag/Intent/';
  9. $filesBefore = 0;
  1. }
  2. // ============================================================================
  3. // 6. Reset Ambiguity Cache (TASK 4 - Cache Migration)
  4. // ============================================================================
  5. if (in_array('ambiguity', $cacheTypes)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. try {
  7. // Count ambiguity cache files before (new location - all files)
  8. $ambiguityCacheDir = CLICSHOPPING::getConfig('dir_root', 'Shop') . 'Work/Cache/Rag/Ambiguity/';
  9. $filesBefore = 0;
  1. }
  2. // ============================================================================
  3. // 7. Reset Translation Ambiguity Cache
  4. // ============================================================================
  5. if (in_array('translation_ambiguity', $cacheTypes)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. try {
  7. // Count translation ambiguity cache files before (new location)
  8. $translationAmbiguityCacheDir = CLICSHOPPING::getConfig('dir_root', 'Shop') . 'Work/Cache/Rag/Translation/';
  9. $filesBefore = 0;
  1. }
  2. // ============================================================================
  3. // 8. Reset Context Cache
  4. // ============================================================================
  5. if (in_array('context', $cacheTypes)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. try {
  7. // Count context cache files before (new location)
  8. $contextCacheDir = CLICSHOPPING::getConfig('dir_root', 'Shop') . 'Work/Cache/Rag/Context/';
  9. $filesBefore = 0;
  1. }
  2. // ============================================================================
  3. // 8.5. Reset Memory Cache (file-based)
  4. // ============================================================================
  5. if (in_array('memory', $cacheTypes)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. try {
  7. $memoryCacheDir = CLICSHOPPING::getConfig('dir_root', 'Shop') . 'Work/Cache/Rag/Memory/';
  8. $filesBefore = 0;
  9. if (is_dir($memoryCacheDir)) {
  1. }
  2. // ============================================================================
  3. // 9. Reset Embedding Cache
  4. // ============================================================================
  5. if (in_array('embedding', $cacheTypes)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. try {
  7. // Count embedding cache files before (new location)
  8. $embeddingCacheDir = CLICSHOPPING::getConfig('dir_root', 'Shop') . 'Work/Cache/Rag/Embedding/';
  9. $filesBefore = 0;
  1. }
  2. // ============================================================================
  3. // 10. Reset EmbeddingSearch Cache
  4. // ============================================================================
  5. if (in_array('embedding_search', $cacheTypes)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. try {
  7. // Count embedding search cache files before (new location)
  8. $embeddingSearchCacheDir = CLICSHOPPING::getConfig('dir_root', 'Shop') . 'Work/Cache/Rag/EmbeddingSearch/';
  9. $filesBefore = 0;
  1. }
  2. // ============================================================================
  3. // 11. Reset Hybrid Query Cache (TASK 8: Multi-temporal query caching)
  4. // ============================================================================
  5. if (in_array('hybrid', $cacheTypes)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. try {
  7. // Count hybrid cache files before
  8. $hybridCacheDir = CLICSHOPPING::getConfig('dir_root', 'Shop') . 'Work/Cache/Rag/Hybrid/';
  9. $filesBefore = 0;
  1. }
  2. // ============================================================================
  3. // 12. Reset Semantic Query Cache (TASK 8: Multi-temporal query caching)
  4. // ============================================================================
  5. if (in_array('semantic', $cacheTypes)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. try {
  7. // Count hybrid cache files before
  8. $semanticCacheDir = CLICSHOPPING::getConfig('dir_root', 'Shop') . 'Work/Cache/Rag/Semantic/';
  9. $filesBefore = 0;
  1. }
  2. // ============================================================================
  3. // 13. Reset Embeddings Cache (PHASE 2 - NewVector cache)
  4. // ============================================================================
  5. if (in_array('embeddings', $cacheTypes)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. try {
  7. $embeddingsCacheDir = CLICSHOPPING::getConfig('dir_root', 'Shop') . 'Work/Cache/Rag/Embeddings/';
  8. $filesBefore = 0;
  9. if (is_dir($embeddingsCacheDir)) {
  1. }
  2. // ============================================================================
  3. // 14. Reset SQL Query Cache (PHASE 4)
  4. // ============================================================================
  5. if (in_array('sql', $cacheTypes)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. try {
  7. $sqlCacheDir = CLICSHOPPING::getConfig('dir_root', 'Shop') . 'Work/Cache/Rag/SQL/';
  8. $filesBefore = 0;
  9. if (is_dir($sqlCacheDir)) {
  1. }
  2. // ============================================================================
  3. // 15. Reset Security Cache
  4. // ============================================================================
  5. if (in_array('security', $cacheTypes)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. try {
  7. $securityCacheDir = CLICSHOPPING::getConfig('dir_root', 'Shop') . 'Work/Cache/Rag/Security/';
  8. $filesBefore = 0;
  9. if (is_dir($securityCacheDir)) {
  1. }
  2. // ============================================================================
  3. // 16. Reset Reputation Cache
  4. // ============================================================================
  5. if (in_array('reputation', $cacheTypes)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. try {
  7. $reputationCacheDir = CLICSHOPPING::getConfig('dir_root', 'Shop') . 'Work/Cache/Rag/Reputation/';
  8. $filesBefore = 0;
  9. if (is_dir($reputationCacheDir)) {
  1. }
  2. // ============================================================================
  3. // 17. Reset Config Cache
  4. // ============================================================================
  5. if (in_array('config', $cacheTypes)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. try {
  7. $configCacheDir = CLICSHOPPING::getConfig('dir_root', 'Shop') . 'Work/Cache/Rag/Config/';
  8. $filesBefore = 0;
  9. if (is_dir($configCacheDir)) {
  1. unset($this->storage[$scopedKey]);
  2. unset($this->metadata[$scopedKey]);
  3. // Remove from the scope's key list
  4. $scopeKeys = $this->scopes[$this->currentScope] ?? [];
  5. $index = array_search($scopedKey, $scopeKeys);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. if ($index !== false) {
  7. array_splice($this->scopes[$this->currentScope], $index, 1);
  8. }
  1. // Use higher priority
  2. $priorities = ['low' => 1, 'medium' => 2, 'high' => 3, 'critical' => 4];
  3. $priority1 = $priorities[$obj1->getPriority()];
  4. $priority2 = $priorities[$obj2->getPriority()];
  5. $combinedPriority = array_search(max($priority1, $priority2), $priorities);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. // Estimate combined time (not just sum, as there may be synergies)
  7. $estimatedTime = (int)(($obj1->getEstimatedCompletionTime() + $obj2->getEstimatedCompletionTime()) * 0.8);
  8. return [
  1. private function translateMonthName(string $monthName, string $languageCode): string
  2. {
  3. $englishMonths = ['January', 'February', 'March', 'April', 'May', 'June',
  4. 'July', 'August', 'September', 'October', 'November', 'December'];
  5. $monthIndex = array_search(ucfirst(strtolower($monthName)), $englishMonths);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. if ($monthIndex === false) {
  7. return $monthName; // Return as-is if not found
  8. }
  9. $targetMonths = $this->getMonthNames($languageCode);
  1. if ($field === $idColumn) {
  2. return true;
  3. }
  4. // Exclude system timestamp fields
  5. if (in_array($field, ['created_at', 'updated_at', 'deleted_at'])) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. return false;
  7. }
  8. // Get column type
  9. $type = $columnTypes[$field] ?? 'string';
  1. // Get column type
  2. $type = $columnTypes[$field] ?? 'string';
  3. // Include numeric columns (for aggregation)
  4. if (in_array($type, ['int', 'bigint', 'smallint', 'decimal', 'float', 'double'])) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  5. return true;
  6. }
  7. // Include date/timestamp columns (for temporal analysis)
  8. if (in_array($type, ['date', 'datetime', 'timestamp', 'time'])) {
  1. if (in_array($type, ['int', 'bigint', 'smallint', 'decimal', 'float', 'double'])) {
  2. return true;
  3. }
  4. // Include date/timestamp columns (for temporal analysis)
  5. if (in_array($type, ['date', 'datetime', 'timestamp', 'time'])) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. return true;
  7. }
  8. // Include text columns (for filtering and grouping)
  9. if (in_array($type, ['varchar', 'char', 'text', 'enum'])) {
  1. if (in_array($type, ['date', 'datetime', 'timestamp', 'time'])) {
  2. return true;
  3. }
  4. // Include text columns (for filtering and grouping)
  5. if (in_array($type, ['varchar', 'char', 'text', 'enum'])) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. return true;
  7. }
  8. // Exclude everything else (binary, blob, json, etc.)
  9. return false;
  1. // Prefer 'normalized'; fall back to 'normalized_value' for forward-compat
  2. $scoreDescription = (float) ($factor['normalized'] ?? $factor['normalized_value'] ?? 0.0);
  3. }
  4. }
  5. $finalQuadrant = in_array($quadrant, ['Q1', 'Q2', 'Q3', 'Q4']) ? $quadrant : 'Q_intermediate';
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. return [
  7. 'quadrant' => $finalQuadrant,
  8. 'score_x' => (float) ($scoreXResult['score'] ?? 0.0),
  9. 'score_y' => (float) ($scoreYResult['score'] ?? 0.0),
  1. $fields = DoctrineOrm::getTableColumns($tableName);
  2. // Exclude only ID and system timestamp fields
  3. return array_values(array_filter($fields, function($field) use ($idColumn) {
  4. return $field !== $idColumn
  5. && !in_array($field, ['created_at', 'updated_at', 'deleted_at']);
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. }));
  7. } catch (\Exception $e) {
  8. return [];
  9. }
  1. $words = preg_split('/[\s,.:;!?"()]+/u', mb_strtolower($onlyText), -1, PREG_SPLIT_NO_EMPTY);
  2. $grammar = $this->grammar();
  3. $counts = [];
  4. foreach ($words as $w) {
  5. $w = preg_replace('/[^\p{L}\p{N}\-]/u', '', $w);
  6. if (mb_strlen($w) > 2 && !in_array($w, $grammar)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  7. $counts[$w] = ($counts[$w] ?? 0) + 1;
  8. }
  9. }
  10. arsort($counts);
  11. $report['wordcountmax'] = array_slice($counts, 0, 8, true);
  1. $productData = $this->getProductData($productId);
  2. if ($productData && !$productData['in_stock']) {
  3. $messages[] = [
  4. 'type' => 'error',
  5. 'code' => 'out_of_stock',
  6. 'param' => '$.line_items[' . array_search($lineItem, $lineItems) . ']',
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  7. 'content_type' => 'plain',
  8. 'content' => 'Produit ' . $productData['title'] . ' temporairement indisponible'
  9. ];
  10. }
  11. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_ECOMMERCE_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_ECOMMERCE_INSTALLED', implode(';', $installed));
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_ECOMMERCE_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_ECOMMERCE_INSTALLED', implode(';', $installed));
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_ECOMMERCE_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_ECOMMERCE_INSTALLED', implode(';', $installed));
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_ECOMMERCE_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_ECOMMERCE_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_PRODUCTS_ARCHIVE_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_PRODUCTS_ARCHIVE_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. // make sure no duplicate category IDs exist which could lock the server in a loop
  2. $tmp_array = [];
  3. $n = count($cPath_array);
  4. for ($i = 0; $i < $n; $i++) {
  5. if (!in_array($cPath_array[$i], $tmp_array)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. $tmp_array[] = $cPath_array[$i];
  7. }
  8. }
  9. return $tmp_array;
  1. $category_name = $this->getCategoryTreeTitle($category['name']);
  2. $categories_url = $this->getCategoryTreeUrl($category_link);
  3. if (($this->follow_cpath === true) && in_array($category_id, $this->cpath_array)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  4. $link_title = $this->cpath_start_string . $category_name . $this->cpath_end_string;
  5. } else {
  6. $link_title = $category_name;
  7. }
  1. $result .= $this->parent_end_string;
  2. }
  3. if (isset($this->_data[$category_id]) && (($this->max_level == '0') || ($this->max_level > $level + 1))) {
  4. if ($this->follow_cpath === true) {
  5. if (in_array($category_id, $this->cpath_array)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. $result .= $this->_buildBranch($category_id, $level + 1);
  7. }
  8. } else {
  9. $result .= $this->_buildBranch($category_id, $level + 1);
  10. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_PRODUCTS_CATEGORIES_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_PRODUCTS_CATEGORIES_INSTALLED', implode(';', $installed));
  1. $categories_id = HTML::sanitize($this->Id);
  2. $new_parent_id = HTML::sanitize($this->moveToCategoryID);
  3. $path = explode('_', $this->categoriesAdmin->getGeneratedCategoryPathIds($new_parent_id));
  4. if (\in_array($this->Id, $path)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  5. $CLICSHOPPING_MessageStack->add($this->app->getDef('error_cannot_move_directory_to_parent'), 'error');
  6. $this->app->redirect('Categories&cPath=' . $this->cPath . '&cID=' . $categories_id);
  7. } else {
  8. $sql_array = [
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_MANUFACTURERS_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_MANUFACTURERS_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_CATALOG_PRODUCTS_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_CATALOG_PRODUCTS_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_PRODUCTS_ATTRIBUTES_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_PRODUCTS_ATTRIBUTES_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_SUPPLIERS_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_SUPPLIERS_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_EMAIL_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_EMAIL_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_NEWSLETTER_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_NEWSLETTER_INSTALLED', implode(';', $installed));
  1. } else {
  2. $chosen = [];
  3. foreach ($_POST['chosen'] as $id) {
  4. if (is_numeric($id) && !\in_array($id, $chosen)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  5. $chosen[] = $id;
  6. }
  7. }
  8. $ids = array_map(function ($k) {
  1. }
  2. } else {
  3. $chosen = [];
  4. foreach ($_POST['chosen'] as $id) {
  5. if (is_numeric($id) && !\in_array($id, $chosen)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. $chosen[] = $id;
  7. }
  8. }
  9. $ids = array_map(function ($k) {
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. $allowed = array_map(function ($v) {
  2. return basename($v, '.php');
  3. }, glob(CLICSHOPPING::BASE_DIR . 'Apps/Communication/Newsletter/Module/ClicShoppingAdmin/Newsletter/*.php'));
  4. if (!\in_array($newsletter_module, $allowed)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  5. $CLICSHOPPING_MessageStack->add($CLICSHOPPING_Newsletter->getDef('error_newsletter_module_not_exists'), 'danger');
  6. $newsletter_error = true;
  7. }
  8. if ($newsletters_accept_file == 'on') {
  1. $allowed = array_map(function ($v) {
  2. return basename($v, '.php');
  3. }, glob(CLICSHOPPING::BASE_DIR . 'Apps/Communication/Newsletter/Module/ClicShoppingAdmin/Newsletter/*.php'));
  4. if (!\in_array($newsletter_module, $allowed)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  5. $CLICSHOPPING_MessageStack->add($CLICSHOPPING_Newsletter->getDef('error_newsletter_module_not_exists'), 'danger');
  6. $newsletter_error = true;
  7. }
  8. if ($newsletters_accept_file == 'on') {
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_PAGE_MANAGER_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_PAGE_MANAGER_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_ADMINISTRATORS_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_ADMINISTRATORS_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. foreach ($Qips as $allowedIp) {
  2. $ip = $allowedIp['ip'];
  3. if ($ip === '127.0.0.1' || $ip === 'localhost') {
  4. if (in_array($clientIp, ['127.0.0.1', '::1'])) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  5. self::logSecurityEvent('Localhost access granted', [
  6. 'api_id' => $api_id,
  7. 'client_ip' => $clientIp
  8. ]);
  1. */
  2. public static function isLocalEnvironment(): bool
  3. {
  4. $ip = HTTP::getIpAddress();
  5. if (in_array($ip, ['127.0.0.1', '::1'])) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. return true;
  7. }
  8. $serverName = $_SERVER['SERVER_NAME'] ?? '';
  9. $host = $_SERVER['HTTP_HOST'] ?? '';
  1. }
  2. $method = strtoupper($_SERVER["REQUEST_METHOD"]);
  3. $allowedMethods = ['GET', 'POST', 'PUT', 'DELETE', 'PATCH', 'OPTIONS'];
  4. if (!in_array($method, $allowedMethods)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  5. throw new Exception("Invalid HTTP method: " . $method);
  6. }
  7. return $method;
  8. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_API_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_API_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_CACHE_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_CACHE_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. foreach ($models as $model) {
  2. $modelId = $model['id'];
  3. $provider = $model['provider'] ?? 'openai'; // Default to openai if missing
  4. // Validate provider name
  5. if (!in_array($provider, $validProviders)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. if (defined('CLICSHOPPING_APP_CHATGPT_CH_DEBUG') && CLICSHOPPING_APP_CHATGPT_CH_DEBUG === 'True') {
  7. error_log("WARNING: Invalid provider '$provider' for model '$modelId'. Using 'openai' as default.");
  8. }
  9. $provider = 'openai';
  10. }
  1. 'open-mistral-nemo',
  2. 'open-codestral-mamba',
  3. 'mistral-moderation-latest'
  4. ];
  5. if (empty($model) || !in_array($model, $valid_models)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. $model = 'mistral-large-latest';
  7. }
  8. $config = new MistralAIChat();
  9. $config->apiKey = $api_key;
  1. }
  2. // Validate type is one of expected values
  3. if (isset($response['type'])) {
  4. $validTypes = ['analytics', 'semantic', 'web_search', 'hybrid', 'error', 'clarification'];
  5. if (!in_array($response['type'], $validTypes)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. $warnings[] = "Unexpected type value: {$response['type']}";
  7. }
  8. }
  9. return [
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_CHATGPT_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_CHATGPT_INSTALLED', implode(';', $installed));
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_CHATGPT_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_CHATGPT_INSTALLED', implode(';', $installed));
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_CHATGPT_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_CHATGPT_INSTALLED', implode(';', $installed));
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_CHATGPT_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_CHATGPT_INSTALLED', implode(';', $installed));
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_CHATGPT_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_CHATGPT_INSTALLED', implode(';', $installed));
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_CHATGPT_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_CHATGPT_INSTALLED', implode(';', $installed));
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_CHATGPT_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_CHATGPT_INSTALLED', implode(';', $installed));
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_CHATGPT_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_CHATGPT_INSTALLED', implode(';', $installed));
  1. exit;
  2. }
  3. // Validate feedback_type
  4. $validTypes = ['positive', 'negative', 'correction'];
  5. if (!in_array($input['feedback_type'], $validTypes)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. echo json_encode([
  7. 'success' => false,
  8. 'error' => 'feedback_type must be one of: ' . implode(', ', $validTypes)
  9. ]);
  10. exit;
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_COUNTRIES_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_COUNTRIES_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_CURRENCY_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_CURRENCY_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_LANGUES_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_LANGUES_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. }
  2. foreach (glob(CLICSHOPPING::getConfig('dir_root', 'ClicShoppingAdmin') . 'Core/languages/*', GLOB_ONLYDIR) as $dir) {
  3. $code = basename($dir);
  4. if (array_search($code, array_column($directories, 'id')) === false) {
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  5. $directories[] = ['id' => $code,
  6. 'text' => $code
  7. ];
  8. }
  9. }
  1. }
  2. foreach (glob(CLICSHOPPING::getConfig('dir_root', 'ClicShoppingAdmin') . 'Core/languages/*', GLOB_ONLYDIR) as $dir) {
  3. $code = basename($dir);
  4. if (array_search($code, array_column($directories, 'id')) === false) {
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  5. $directories[] = ['id' => $code,
  6. 'text' => $code
  7. ];
  8. }
  9. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_MODULES_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_MODULES_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. $module->install();
  2. $modules_installed = explode(';', \constant($module_key));
  3. if (!\in_array($class . $file_extension, $modules_installed)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  4. $modules_installed[] = $class . $file_extension;
  5. }
  6. Registry::get('Db')->save('configuration', ['configuration_value' => implode(';', $modules_installed)],
  7. ['configuration_key' => $module_key]
  1. $module->remove();
  2. $modules_installed = explode(';', \constant($module_key));
  3. if (\in_array($class . $file_extension, $modules_installed)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  4. unset($modules_installed[array_search($class . $file_extension, $modules_installed)]);
  5. }
  6. Registry::get('Db')->save('configuration', ['configuration_value' => implode(';', $modules_installed)],
  7. ['configuration_key' => $module_key]
  1. $module->remove();
  2. $modules_installed = explode(';', \constant($module_key));
  3. if (\in_array($class . $file_extension, $modules_installed)) {
  4. unset($modules_installed[array_search($class . $file_extension, $modules_installed)]);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  5. }
  6. Registry::get('Db')->save('configuration', ['configuration_value' => implode(';', $modules_installed)],
  7. ['configuration_key' => $module_key]
  8. );
  1. if ($dir = @dir($module_directory)) {
  2. while ($file = $dir->read()) {
  3. if (!is_dir($module_directory . $file)) {
  4. if (substr($file, strrpos($file, '.')) == $file_extension) {
  5. if (isset($_GET['list']) && ($_GET['list'] == 'new')) {
  6. if (!\in_array($file, $modules_installed)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  7. $directory_array[] = $file;
  8. }
  9. } else {
  10. if (\in_array($file, $modules_installed)) {
  11. $directory_array[] = $file;
  1. if (isset($_GET['list']) && ($_GET['list'] == 'new')) {
  2. if (!\in_array($file, $modules_installed)) {
  3. $directory_array[] = $file;
  4. }
  5. } else {
  6. if (\in_array($file, $modules_installed)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  7. $directory_array[] = $file;
  8. } else {
  9. $new_modules_counter++;
  10. }
  11. }
  1. }
  2. if (isset($appModuleType)) {
  3. foreach (Apps::getModules($appModuleType) as $k => $v) {
  4. if (isset($_GET['list']) && ($_GET['list'] == 'new')) {
  5. if (!\in_array($k, $modules_installed)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. $directory_array[] = $k;
  7. }
  8. } else {
  9. if (\in_array($k, $modules_installed)) {
  10. $directory_array[] = $k;
  1. if (isset($_GET['list']) && ($_GET['list'] == 'new')) {
  2. if (!\in_array($k, $modules_installed)) {
  3. $directory_array[] = $k;
  4. }
  5. } else {
  6. if (\in_array($k, $modules_installed)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  7. $directory_array[] = $k;
  8. } else {
  9. $new_modules_counter++;
  10. }
  11. }
  1. if ($dir = @dir($module_directory)) {
  2. while ($file = $dir->read()) {
  3. if (!is_dir($module_directory . $file)) {
  4. if (substr($file, strrpos($file, '.')) === $file_extension) {
  5. if (isset($_GET['list']) && ($_GET['list'] == 'new')) {
  6. if (!\in_array($file, $modules_installed)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  7. $directory_array[] = $file;
  8. }
  9. } else {
  10. if (\in_array($file, $modules_installed)) {
  11. $directory_array[] = $file;
  1. if (isset($_GET['list']) && ($_GET['list'] == 'new')) {
  2. if (!\in_array($file, $modules_installed)) {
  3. $directory_array[] = $file;
  4. }
  5. } else {
  6. if (\in_array($file, $modules_installed)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  7. $directory_array[] = $file;
  8. } else {
  9. $new_modules_counter++;
  10. }
  11. }
  1. }
  2. if (isset($appModuleType)) {
  3. foreach (Apps::getModules($appModuleType) as $k => $v) {
  4. if (isset($_GET['list']) && ($_GET['list'] == 'new')) {
  5. if (!\in_array($k, $modules_installed)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. $directory_array[] = $k;
  7. }
  8. } else {
  9. if (\in_array($k, $modules_installed)) {
  10. $directory_array[] = $k;
  1. if (isset($_GET['list']) && ($_GET['list'] == 'new')) {
  2. if (!\in_array($k, $modules_installed)) {
  3. $directory_array[] = $k;
  4. }
  5. } else {
  6. if (\in_array($k, $modules_installed)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  7. $directory_array[] = $k;
  8. } else {
  9. $new_modules_counter++;
  10. }
  11. }
  1. <tr>
  2. <td><?php echo $module->title; ?></td>
  3. <td class="text-start"><?php echo $module->group; ?></td>
  4. <td class="text-end">
  5. <?php
  6. if (\in_array($module->code . $file_extension, $modules_installed) && is_numeric($module->sort_order)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  7. echo $module->sort_order;
  8. }
  9. ?>
  10. </td>
  11. <td class="text-center">
  1. $Qcheck = $CLICSHOPPING_Db->get('configuration', 'configuration_value', ['configuration_key' => 'TEMPLATE_BLOCK_GROUPS']);
  2. if ($Qcheck->fetch() !== false) {
  3. $tbgroups_array = explode(';', $Qcheck->value('configuration_value'));
  4. if (!\in_array($module_type, $tbgroups_array)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  5. $tbgroups_array[] = $module_type;
  6. sort($tbgroups_array);
  7. $CLICSHOPPING_Db->save('configuration', [
  8. 'configuration_value' => implode(';', $tbgroups_array),
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_ORDERS_STATUS_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_ORDERS_STATUS_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_ORDERS_STATUS_INVOICE_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_ORDERS_STATUS_INVOICE_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_PROUCTS_LENGTH_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_PROUCTS_LENGTH_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_PRODUCTS_QUANTITY_UNIT_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_PRODUCTS_QUANTITY_UNIT_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_SETTINGS_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_SETTINGS_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_TAX_CLASS_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_TAX_CLASS_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_TAX_GEO_ZONES_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_TAX_GEO_ZONES_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_TAX_RATES_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_TAX_RATES_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_TEMPLATE_EMAIL_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_TEMPLATE_EMAIL_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_WEIGHT_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_WEIGHT_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_ZONES_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_ZONES_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_CUSTOMERS_INFO_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_CUSTOMERS_INFO_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_CUSTOMERS_GDPR_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_CUSTOMERS_GDPR_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_CUSTOMERS_GROUPS_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_CUSTOMERS_GROUPS_INSTALLED', implode(';', $installed));
  1. for ($i = 0, $n = \count($include_modules); $i < $n; $i++) {
  2. if (str_contains($include_modules[$i]['class'], '\\')) {
  3. Registry::set('Payment_' . str_replace('\\', '_', $include_modules[$i]['class']), new $include_modules[$i]['file']);
  4. $module = Registry::get('Payment_' . str_replace('\\', '_', $include_modules[$i]['class']));
  5. if (($cInfo->customers_group_id != 0) && (\in_array($module->code, $payments_unallowed))) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. $content .= '<div class="row">';
  7. $content .= '<div class="col-md-5">';
  8. $content .= '<div class="form-group row">';
  9. $content .= '<div class="col-md-12">';
  10. $content .= '<span class="col-md-1"><i class="bi-check text-success"></i></span>';
  1. for ($i = 0, $n = \count($include_modules); $i < $n; $i++) {
  2. if (str_contains($include_modules[$i]['class'], '\\')) {
  3. Registry::set('Shipping_' . str_replace('\\', '_', $include_modules[$i]['class']), new $include_modules[$i]['file']);
  4. $module = Registry::get('Shipping_' . str_replace('\\', '_', $include_modules[$i]['class']));
  5. if (($cInfo->customers_group_id != 0) && (\in_array($module->code, $shipping_unallowed))) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. $content .= '<div class="col-md-12">';
  7. $content .= '<span class="col-md-1"><i class="bi-check text-success"></i></span>';
  8. $content .= '<span class="col-md-3">' . $module->title . '</span>';
  9. $content .= '</div>';
  10. } elseif ($cInfo->customers_group_id != 0 && !\in_array($module->code, $shipping_unallowed)) {
  1. if (($cInfo->customers_group_id != 0) && (\in_array($module->code, $shipping_unallowed))) {
  2. $content .= '<div class="col-md-12">';
  3. $content .= '<span class="col-md-1"><i class="bi-check text-success"></i></span>';
  4. $content .= '<span class="col-md-3">' . $module->title . '</span>';
  5. $content .= '</div>';
  6. } elseif ($cInfo->customers_group_id != 0 && !\in_array($module->code, $shipping_unallowed)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  7. $content .= '<div class="col-md-12">';
  8. $content .= '<span class="col-md-1"><i class="bi-check text-danger"></i></span>';
  9. $content .= '<span class="col-md-3">' . $module->title . '</span>';
  10. $content .= '</div>';
  11. } elseif ($cInfo->customers_group_id == 0) {
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. <div class="form-group row">
  2. <div class="col-md-12">
  3. <ul class="list-group-slider list-group-flush">
  4. <li class="list-group-item-slider">
  5. <label class="switch">
  6. <?php echo HTML::checkboxField('payment_unallowed[' . $i . ']', $module->code, (\in_array($module->code, $payments_unallowed)) ? true : false, 'class="success"'); ?>
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  7. <span class="slider"></span>
  8. </label>
  9. </li>
  10. <span class="text-slider"><?php echo $module->title; ?></span>
  11. </ul>
  1. <div class="form-group row">
  2. <div class="col-md-12">
  3. <ul class="list-group-slider list-group-flush">
  4. <li class="list-group-item-slider">
  5. <label class="switch">
  6. <?php echo HTML::checkboxField('shipping_unallowed[' . $i . ']', $module->code, (\in_array($module->code, $shipping_unallowed)) ? true : false, 'class="success"'); ?>
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  7. <span class="slider"></span>
  8. </label>
  9. </li>
  10. <span class="text-slider"><?php echo $module->title; ?></span>
  11. </ul>
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_CUSTOMERS_MEMBERS_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_CUSTOMERS_MEMBERS_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_REVIEWS_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_REVIEWS_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_BANNER_MANAGER_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_BANNER_MANAGER_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_PRODUCTS_FAVORITES_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_PRODUCTS_FAVORITES_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_PRODUCTS_FEATURED_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_PRODUCTS_FEATURED_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_PRODUCTS_PRODUCT_RECOMMENDATIONS_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_PRODUCTS_PRODUCT_RECOMMENDATIONS_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_SEO_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_SEO_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_PRODUCTS_SPECIALS_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_PRODUCTS_SPECIALS_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_ORDER_TOTAL_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_ORDER_TOTAL_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_ORDER_TOTAL_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_ORDER_TOTAL_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_ORDER_TOTAL_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_ORDER_TOTAL_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_ORDER_TOTAL_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_ORDER_TOTAL_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_ORDERS_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_ORDERS_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_PRODUCTS_RETURN_ORDERS_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_PRODUCTS_RETURN_ORDERS_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_PAYMENT_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_PAYMENT_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_PAYMENT_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_PAYMENT_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_PAYMENT_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_PAYMENT_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_STATS_PRODUCTS_NOTIFICATION_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_STATS_PRODUCTS_NOTIFICATION_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_SHIPPING_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_SHIPPING_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_SHIPPING_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_SHIPPING_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. $CLICSHOPPING_Language = Registry::get('Language');
  2. $module = HTML::sanitize(str_replace(' ', '', $module));
  3. if (defined('MODULE_ACTION_RECORDER_INSTALLED') && !is_null(MODULE_ACTION_RECORDER_INSTALLED)) {
  4. if (!is_null($module) && in_array($module . '.' . substr(CLICSHOPPING::getIndex(), (strrpos(CLICSHOPPING::getIndex(), '.') + 1)), explode(';', MODULE_ACTION_RECORDER_INSTALLED))) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  5. if (!class_exists($module)) {
  6. if (is_file($CLICSHOPPING_Template->getModuleDirectory() . '/action_recorder/' . $module . '.' . substr(CLICSHOPPING::getIndex(), (strrpos(CLICSHOPPING::getIndex(), '.') + 1)))) {
  7. $CLICSHOPPING_Language->loadDefinitions('modules/action_recorder/' . $module);
  8. include($CLICSHOPPING_Template->getModuleDirectory() . '/action_recorder/' . $module . '.' . substr(CLICSHOPPING::getIndex(), (strrpos(CLICSHOPPING::getIndex(), '.') + 1)));
  9. } else {
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_ACTIONS_RECORDER_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_ACTIONS_RECORDER_INSTALLED', implode(';', $installed));
  1. $modules_array[] = $Qmodules->value('module');
  2. }
  3. $expired_entries = 0;
  4. if (isset($_GET['module']) && \in_array($_GET['module'], $modules_array)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  5. $get_module_class = $CLICSHOPPING_ActionsRecorderClass->getClassModule($_GET['module']);
  6. if (\is_object($get_module_class)) {
  7. $expired_entries += $get_module_class->expireEntries();
  8. } else {
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. echo HTML::form('search', $CLICSHOPPING_ActionsRecorder->link('ActionsRecorder'), 'post', '', ['session_id' => true]);
  2. echo HTML::selectField('module', $modules_list_array, null, 'onchange="this.form.submit();"');
  3. ?>
  4. </span>
  5. <span class="col-md-1 text-end">
  6. <?php echo HTML::button($CLICSHOPPING_ActionsRecorder->getDef('button_reset'), null, $CLICSHOPPING_ActionsRecorder->link('ActionsRecorder&Expire' . (isset($_POST['module']) && \in_array($_POST['module'], $modules_array) ? '&module=' . $_POST['module'] : '')), 'danger'); ?>
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  7. </span>
  8. </div>
  9. </form>
  10. </div>
  11. </div>
  1. </thead>
  2. <tbody>
  3. <?php
  4. $filter = [];
  5. if (isset($_POST['module']) && \in_array($_POST['module'], $modules_array)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. $filter[] = 'module = :module';
  7. }
  8. if (isset($_POST['search']) && !empty($_POST['search'])) {
  9. $filter[] = 'identifier like :identifier';
  1. $sql_query .= ' order by date_added desc limit :page_set_offset, :page_set_max_results';
  2. $Qactions = $CLICSHOPPING_ActionsRecorder->db->prepare($sql_query);
  3. if (!empty($filter)) {
  4. if (isset($_POST['module']) && \in_array($_POST['module'], $modules_array)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  5. $Qactions->bindValue(':module', $_POST['module']);
  6. }
  7. if (isset($_POST['search']) && !empty($_POST['search'])) {
  8. $Qactions->bindValue(':identifier', '%' . $_POST['search'] . '%');
  1. <div class="row">
  2. <div class="col-md-12">
  3. <div
  4. class="col-md-6 float-start pagenumber hidden-xs TextDisplayNumberOfLink"><?php echo $Qactions->getPageSetLabel($CLICSHOPPING_ActionsRecorder->getDef('text_display_number_of_link')); ?></div>
  5. <div
  6. class="float-end text-end"> <?php echo $Qactions->getPageSetLinks((isset($_POST['module']) && \in_array($_POST['module'], $modules_array) && \is_object($GLOBALS[$_POST['module']]) ? 'module=' . $_POST['module'] : null) . '&' . (isset($_POST['search']) && !empty($_POST['search']) ? 'search=' . $_POST['search'] : null)); ?></div>
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  7. </div>
  8. </div>
  9. </div>
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_ADMINISTRATOR_MENU_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_ADMINISTRATOR_MENU_INSTALLED', implode(';', $installed));
  1. if (isset($this->Id) && ($this->Id != $this->moveToCategoryID)) {
  2. $new_parent_id = $this->moveToCategoryID;
  3. $path = explode('_', AdministratorMenu::getGeneratedAdministratorMenuPathIds($new_parent_id));
  4. if (\in_array($this->Id, $path)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  5. $CLICSHOPPING_MessageStack->add($this->app->getDef('error_cannot_move_directory_to_parent'), 'error');
  6. $this->app->redirect('AdministratorMenu&cPath=' . (int)$this->cPath . '&cID=' . (int)$this->Id);
  7. } else {
  8. $this->app->db->save('administrator_menu', [
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_APPS_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_APPS_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_BACKUP_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_BACKUP_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. $dir = dir($backup_directory);
  2. $contents = [];
  3. while ($file = $dir->read()) {
  4. if (!is_dir($backup_directory . $file) && \in_array(substr($file, -3), array('zip', 'sql', '.gz'))) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  5. $contents[] = $file;
  6. }
  7. }
  8. sort($contents);
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_CRONJOB_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_CRONJOB_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_DATA_BASE_TABLES_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_DATA_BASE_TABLES_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. ['id' => 'utf8',
  2. 'text' => $CLICSHOPPING_DataBaseTables->getDef('action_utf8_conversion')
  3. ]);
  4. if (isset($_POST['action'])) {
  5. if (\in_array($_POST['action'], array('check', 'analyze', 'optimize', 'repair', 'utf8'))) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if (isset($_POST['id']) && \is_array($_POST['id']) && !empty($_POST['id'])) {
  7. $tables = Database::getDtTables();
  8. foreach ($_POST['id'] as $key => $value) {
  9. if (!\in_array($value, $tables)) {
  1. if (\in_array($_POST['action'], array('check', 'analyze', 'optimize', 'repair', 'utf8'))) {
  2. if (isset($_POST['id']) && \is_array($_POST['id']) && !empty($_POST['id'])) {
  3. $tables = Database::getDtTables();
  4. foreach ($_POST['id'] as $key => $value) {
  5. if (!\in_array($value, $tables)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. unset($_POST['id'][$key]);
  7. }
  8. }
  9. if (!empty($_POST['id'])) {
  1. while ($Qaction->fetch()) {
  2. $table_data[] = [
  3. ($table != $current_table) ? HTML::outputProtected($table) : '',
  4. $Qaction->valueProtected('Msg_type'),
  5. $Qaction->valueProtected('Msg_text'),
  6. ($table != $current_table) ? HTML::checkboxField('id[]', $table, isset($_POST['id']) && \in_array($table, $_POST['id'])) : ''
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  7. ];
  8. $current_table = $table;
  9. }
  10. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_DEFINE_LANGUAGE_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_DEFINE_LANGUAGE_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. $file_array = new RecursiveIteratorIterator(new RecursiveDirectoryIterator($directory_selected));
  2. foreach ($file_array as $filename => $current) {
  3. $fileInfo = pathinfo($current->getFileName());
  4. if (array_key_exists('extension', $fileInfo) && in_array($fileInfo['extension'], $fileTypes)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  5. $found[] = $current->getFileName();
  6. }
  7. }
  8. if ($found) { // Check the $found array is not empty
  1. $file_array = new RecursiveIteratorIterator(new RecursiveDirectoryIterator($filename_selected));
  2. foreach ($file_array as $filename => $current) {
  3. $fileInfo = pathinfo($current->getFileName());
  4. if (array_key_exists('extension', $fileInfo) && in_array($fileInfo['extension'], $fileTypes)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  5. $found[] = $current->getFileName();
  6. }
  7. }
  8. if ($found) { // Check the $found array is not empty
  1. $file_array = new RecursiveIteratorIterator(new RecursiveDirectoryIterator($template_directory));
  2. foreach ($file_array as $filename => $current) {
  3. $fileInfo = pathinfo($current->getFileName());
  4. if (array_key_exists('extension', $fileInfo) && in_array($fileInfo['extension'], $fileTypes)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  5. $found[] = $current->getFileName();
  6. }
  7. }
  8. if ($found) { // Check the $found array is not empty
  1. /* if empty error is produced : Fatal error: Uncaught exception 'RuntimeException'*/
  2. foreach (new \RecursiveIteratorIterator(new \RecursiveDirectoryIterator($template_directory)) as $filename => $current) {
  3. $fileInfo = pathinfo($current->getFileName());
  4. if (array_key_exists('extension', $fileInfo) && \in_array($fileInfo['extension'], $fileTypes)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  5. $found[] = $current->getFileName();
  6. }
  7. }
  8. if ($found) { // Check the $found array is not empty
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_EDIT_DESIGN_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_EDIT_DESIGN_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_EDIT_LOG_ERROR_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_EDIT_LOG_ERROR_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. * @param array $checks An array of check results, each with a 'status' key.
  2. * @return string The overall status: 'error', 'warning', or 'healthy'.
  3. */
  4. private function determineOverallStatus(array $checks): string
  5. {
  6. if (in_array('error', array_column($checks, 'status'))) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  7. return 'error';
  8. }
  9. if (in_array('warning', array_column($checks, 'status'))) {
  10. return 'warning';
  11. }
  1. private function determineOverallStatus(array $checks): string
  2. {
  3. if (in_array('error', array_column($checks, 'status'))) {
  4. return 'error';
  5. }
  6. if (in_array('warning', array_column($checks, 'status'))) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  7. return 'warning';
  8. }
  9. return 'healthy';
  10. }
  1. foreach ($Qips as $allowedIp) {
  2. $ip = $allowedIp['ip'];
  3. if ($ip === '127.0.0.1' || $ip === 'localhost') {
  4. if (in_array($clientIp, ['127.0.0.1', '::1'])) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  5. self::logSecurityEvent('Localhost access granted', [
  6. 'mcp_id' => $mcp_id,
  7. 'client_ip' => $clientIp
  8. ]);
  1. */
  2. public static function isLocalEnvironment(): bool
  3. {
  4. $ip = HTTP::getIpAddress();
  5. if (in_array($ip, ['127.0.0.1', '::1'])) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. return true;
  7. }
  8. $serverName = $_SERVER['SERVER_NAME'] ?? '';
  9. $host = $_SERVER['HTTP_HOST'] ?? '';
  1. }
  2. $method = strtoupper($_SERVER["REQUEST_METHOD"]);
  3. $allowedMethods = ['GET', 'POST', 'PUT', 'DELETE', 'PATCH', 'OPTIONS'];
  4. if (!in_array($method, $allowedMethods)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  5. throw new Exception("Invalid HTTP method: " . $method);
  6. }
  7. return $method;
  8. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_MCP_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_MCP_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. /**
  2. * Valide une clé d'API pour un niveau d'accès donné
  3. */
  4. public function validateMcpKey(string $mcpKey, string $accessLevel): bool {
  5. if (!in_array($accessLevel, $this->accessLevels)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. return false;
  7. }
  8. if (!isset($this->validMcpKeys[$accessLevel])) {
  9. return false;
  1. if (!isset($this->validMcpKeys[$accessLevel])) {
  2. return false;
  3. }
  4. return in_array($mcpKey, $this->validMcpKeys[$accessLevel]);
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  5. }
  6. /**
  7. * Valide les headers de sécurité requis
  8. */
  1. 'ssl_enabled' => $sslEnabled,
  2. 'origin' => $origin
  3. ];
  4. // Add to allowed origins list
  5. if (!in_array($origin, $this->allowedOrigins)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. $this->allowedOrigins[] = $origin;
  7. }
  8. }
  9. // Fallback to localhost if no configurations found
  1. /**
  2. * Check if an origin is allowed
  3. */
  4. public function isOriginAllowed(string $origin): bool {
  5. return in_array($origin, $this->allowedOrigins);
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. }
  7. /**
  8. * Valide une clé d'API pour un niveau d'accès donné
  9. */
  1. /**
  2. * Valide une clé d'API pour un niveau d'accès donné
  3. */
  4. public function validateMcpKey(string $mcpKey, string $accessLevel): bool {
  5. if (!in_array($accessLevel, $this->accessLevels)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. return false;
  7. }
  8. if (!isset($this->validMcpKeys[$accessLevel])) {
  9. return false;
  1. if (!isset($this->validMcpKeys[$accessLevel])) {
  2. return false;
  3. }
  4. return in_array($mcpKey, $this->validMcpKeys[$accessLevel]);
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  5. }
  6. /**
  7. * Valide les headers de sécurité requis
  8. */
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_MODULES_HOOKS_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_MODULES_HOOKS_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_SEC_DIR_PERMISSIONS_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_SEC_DIR_PERMISSIONS_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. if ($handle = opendir($path)) {
  2. while (false !== ($filename = readdir($handle))) {
  3. if (!\in_array($filename, $exclude_array)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  4. $file = ['name' => $path . $filename,
  5. 'is_dir' => is_dir($path . $filename),
  6. 'writable' => FileSystem::isWritable($path . $filename)
  7. ];
  1. <th
  2. scope="row"><?php echo substr($file['name'], \strlen(CLICSHOPPING::getConfig('dir_root', 'Shop'))); ?></th>
  3. <td
  4. class="text-center"><?php echo $file['writable'] === true ? '<i class="bi-check text-success"></i>' : '<i class="bi bi-x text-danger"></i>'; ?></td>
  5. <td
  6. class="text-center"><?php echo(\in_array(substr($file['name'], \strlen(CLICSHOPPING::getConfig('dir_root', 'Shop'))), $whitelist_array) ? '<i class="bi-check text-success"></i>' : '<i class="bi bi-x text-danger"></i>'); ?></td>
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  7. </tr>
  8. <?php
  9. }
  10. }
  11. ?>
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_SECURITY_CHECK_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_SECURITY_CHECK_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. <?php
  2. foreach ($modules as $module) {
  3. $secCheck = $GLOBALS[$module['class']];
  4. if (!\in_array($secCheck->type, $types)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  5. $secCheck->type = 'info';
  6. }
  7. $output = '';
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_SERVICE_APP_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_SERVICE_APP_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_UPGRADE_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_UPGRADE_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. public function uninstall()
  2. {
  3. parent::uninstall();
  4. $installed = explode(';', MODULE_MODULES_WHOS_ONLINE_INSTALLED);
  5. $installed_pos = array_search($this->app->vendor . '\\' . $this->app->code . '\\' . $this->code, $installed);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($installed_pos !== false) {
  7. unset($installed[$installed_pos]);
  8. $this->app->saveCfgParam('MODULE_MODULES_WHOS_ONLINE_INSTALLED', implode(';', $installed));
  1. $default_module = $m;
  2. break;
  3. }
  4. }
  5. $this->page->data['current_module'] = (isset($_GET['module']) && \in_array($_GET['module'], $modules)) ? $_GET['module'] : $default_module;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. }
  1. continue;
  2. }
  3. $fullClass = self::NAMESPACE_PREFIX . $fileInfo->getBasename('.php');
  4. if (class_exists($fullClass) && in_array(ActionToolsInterface::class, class_implements($fullClass))) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  5. try {
  6. /** @var ActionToolsInterface $toolInstance */
  7. $toolInstance = new $fullClass();
  8. $toolName = $toolInstance->getName();
  9. $this->tools[$toolName] = $fullClass;
  1. $details_string = preg_replace('/comment\(.+\)$/', '', $details_string);
  2. $details = array_filter(explode(' ', $details_string), fn($v) => $v !== null && $v !== '');
  3. $details = array_values($details);
  4. }
  5. $is_binary = array_search('binary', $details);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if (is_int($is_binary)) {
  7. array_splice($details, $is_binary, 1);
  8. $schema['col'][$field_name]['binary'] = true;
  9. }
  1. if (is_int($is_binary)) {
  2. array_splice($details, $is_binary, 1);
  3. $schema['col'][$field_name]['binary'] = true;
  4. }
  5. $is_unsigned = array_search('unsigned', $details);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if (is_int($is_unsigned)) {
  7. array_splice($details, $is_unsigned, 1);
  8. $schema['col'][$field_name]['unsigned'] = true;
  9. }
  1. if (is_int($is_unsigned)) {
  2. array_splice($details, $is_unsigned, 1);
  3. $schema['col'][$field_name]['unsigned'] = true;
  4. }
  5. $is_not_null = array_search('not_null', $details);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if (is_int($is_not_null)) {
  7. array_splice($details, $is_not_null, 1);
  8. $schema['col'][$field_name]['not_null'] = true;
  9. }
  1. if (is_int($is_not_null)) {
  2. array_splice($details, $is_not_null, 1);
  3. $schema['col'][$field_name]['not_null'] = true;
  4. }
  5. $is_auto_increment = array_search('auto_increment', $details);
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if (preg_match('/on_update\(([^)]+)\)/', $details_string, $on_update_match)) {
  7. $schema['col'][$field_name]['on_update'] = $on_update_match[1];
  8. $details_string = preg_replace('/on_update\([^)]+\)/', '', $details_string);
  9. $details = array_values(array_filter(explode(' ', $details_string)));
  1. $this->result = $this->cache_data;
  2. } else {
  3. $fetch_argument = $args[0] ?? null;
  4. $ctor_args = $args[1] ?? [];
  5. if (in_array($fetch_style, [PDO::FETCH_COLUMN])) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. $this->result = parent::fetchAll($fetch_style, $fetch_argument);
  7. } elseif (in_array($fetch_style, [PDO::FETCH_CLASS, PDO::FETCH_FUNC])) {
  8. $this->result = parent::fetchAll($fetch_style, $fetch_argument, $ctor_args);
  9. } else {
  10. $this->result = parent::fetchAll($fetch_style);
  1. $fetch_argument = $args[0] ?? null;
  2. $ctor_args = $args[1] ?? [];
  3. if (in_array($fetch_style, [PDO::FETCH_COLUMN])) {
  4. $this->result = parent::fetchAll($fetch_style, $fetch_argument);
  5. } elseif (in_array($fetch_style, [PDO::FETCH_CLASS, PDO::FETCH_FUNC])) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. $this->result = parent::fetchAll($fetch_style, $fetch_argument, $ctor_args);
  7. } else {
  8. $this->result = parent::fetchAll($fetch_style);
  9. }
  1. */
  2. public function setExcludeEntries(?array $entries)
  3. {
  4. if (is_array($entries)) {
  5. foreach ($entries as $value) {
  6. if (!in_array($value, $this->exclude_entries)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  7. $this->exclude_entries[] = $value;
  8. }
  9. }
  10. } elseif (is_string($entries)) {
  11. if (!in_array($entries, $this->exclude_entries)) {
  1. if (!in_array($value, $this->exclude_entries)) {
  2. $this->exclude_entries[] = $value;
  3. }
  4. }
  5. } elseif (is_string($entries)) {
  6. if (!in_array($entries, $this->exclude_entries)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  7. $this->exclude_entries[] = $entries;
  8. }
  9. }
  10. }
  1. $this->listing = array();
  2. }
  3. if ($dir = @dir($directory)) {
  4. while (($entry = $dir->read()) !== false) {
  5. if (!in_array($entry, $this->exclude_entries)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if (($this->include_files === true) && is_file($dir->path . DIRECTORY_SEPARATOR . $entry)) {
  7. if (empty($this->check_extension) || in_array(mb_strtolower(substr($entry, strrpos($entry, '.') + 1)), $this->check_extension)) {
  8. if ($this->adddirectory_to_filename === true) {
  9. if ($dir->path !== $this->directory) {
  10. $entry = substr($dir->path, strlen($this->directory) + 1) . DIRECTORY_SEPARATOR . $entry;
  1. if ($dir = @dir($directory)) {
  2. while (($entry = $dir->read()) !== false) {
  3. if (!in_array($entry, $this->exclude_entries)) {
  4. if (($this->include_files === true) && is_file($dir->path . DIRECTORY_SEPARATOR . $entry)) {
  5. if (empty($this->check_extension) || in_array(mb_strtolower(substr($entry, strrpos($entry, '.') + 1)), $this->check_extension)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($this->adddirectory_to_filename === true) {
  7. if ($dir->path !== $this->directory) {
  8. $entry = substr($dir->path, strlen($this->directory) + 1) . DIRECTORY_SEPARATOR . $entry;
  9. }
  10. }
  1. * @param string $type The type of the module to check for.
  2. * @return bool Returns true if the module exists, false otherwise.
  3. */
  4. final public function hasModule(string $module, string $type): bool
  5. {
  6. return isset($this->modules[$type]) && in_array($module, $this->modules[$type]);
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  7. }
  8. /**
  9. * Sets the app information by reflecting the current class and loading data
  10. * from a metafile. Assigns the app's code, vendor, title, version, and modules
  1. $field .= ' id="' . static::output(substr($parameters, $offset + 4, strpos($parameters, '"', $offset + 4) - ($offset + 4))) . '_' . $counter . '"';
  2. }
  3. $field .= ' value="' . static::output($selection_value) . '"';
  4. if (isset($default) && (($default === true) || (!is_array($default) && ((string)$default == (string)$selection_value)) || (is_array($default) && in_array($selection_value, $default)))) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  5. $field .= ' checked="checked"';
  6. }
  7. if (!empty($parameters)) {
  8. $field .= ' ' . $parameters;
  1. if (!isset($params['type'])) {
  2. $params['type'] = 'submit';
  3. }
  4. if (!in_array($params['type'], $types)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  5. $params['type'] = 'submit';
  6. }
  7. if (($params['type'] == 'submit') && isset($link)) {
  8. $params['type'] = 'button';
  1. if (($params['type'] == 'submit') && isset($link)) {
  2. $params['type'] = 'button';
  3. }
  4. if (isset($style) && !in_array($style, $styles)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  5. unset($style);
  6. }
  7. if (isset($size) && !in_array($size, $size_button)) {
  8. unset($size);
  1. if (isset($style) && !in_array($style, $styles)) {
  2. unset($style);
  3. }
  4. if (isset($size) && !in_array($size, $size_button)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  5. unset($size);
  6. }
  7. $button = '';
  1. if (!isset($data['cafile'])) {
  2. $data['cafile'] = CLICSHOPPING::BASE_DIR . 'External/cacert.pem';
  3. }
  4. if (isset($data['format']) && !in_array($data['format'], ['json'])) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  5. trigger_error('HttpRequest::getResponse(): Unknown "format": ' . $data['format']);
  6. unset($data['format']);
  7. }
  1. ];
  2. $domain = strtolower(substr(strrchr($email, "@"), 1));
  3. if (in_array($domain, $temp_domains)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  4. return true;
  5. }
  6. }
  7. return false;
  1. $stack = [
  2. 'text' => $message,
  3. 'type' => $type
  4. ];
  5. if (!$this->exists($group) || !in_array($stack, $this->data[$group])) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. $this->data[$group][] = $stack;
  7. }
  8. }
  9. /**
  1. }
  2. }
  3. if (!empty($this->_upload)) {
  4. if (!empty($this->_extensions)) {
  5. if (!in_array(mb_strtolower(substr($this->_upload['name'], strrpos($this->_upload['name'], '.') + 1)), $this->_extensions)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. $CLICSHOPPING_MessageStack->add(CLICSHOPPING::getDef('error_filetype_not_allowed') . implode(', ', $this->_extensions), 'warning');
  7. return false;
  8. }
  9. }
  1. public function isInstalled()
  2. {
  3. $module = HTML::sanitize(str_replace(' ', '', $this->_module));
  4. if (defined('MODULE_ACTION_RECORDER_INSTALLED') && !is_null(MODULE_ACTION_RECORDER_INSTALLED)) {
  5. if (!is_null($module) && \in_array($module . '.' . substr(CLICSHOPPING::getIndex(), (strrpos(CLICSHOPPING::getIndex(), '.') + 1)), explode(';', MODULE_ACTION_RECORDER_INSTALLED))) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if (!class_exists($module)) {
  7. if (is_file(CLICSHOPPING::getConfig('dir_root', 'Shop') . 'Core/modules/action_recorder/' . $module . '.' . substr(CLICSHOPPING::getIndex(), (strrpos(CLICSHOPPING::getIndex(), '.') + 1)))) {
  8. $this->lang->loadDefinitions('Shop/Module/ActionRecorder/' . $module);
  1. $name = (($key) ? 'configuration[' . $key . ']' : 'configuration_value');
  2. foreach ($contents as $item) {
  3. $fileInfo = pathinfo($item);
  4. if (array_key_exists('extension', $fileInfo) && \in_array($fileInfo['extension'], $fileTypes)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  5. $found[] = $item;
  6. }
  7. }
  8. if ($found) { // Check the $found array is not empty
  1. sort($select_array);
  2. $values_array = explode(';', $values);
  3. $output = '';
  4. foreach ($select_array as $file) {
  5. $output .= HTML::checkboxField('ht_datepicker_jquery_file[]', $file, \in_array($file, $values_array)) . '&nbsp;' . HTML::outputProtected($file) . '<br />';
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. if (!empty($output)) {
  8. $output = '<br />' . substr($output, 0, -6);
  9. }
  1. */
  2. public static function checkExecEnabled(): bool
  3. {
  4. $disabled = explode(', ', ini_get('disable_functions'));
  5. return !in_array('exec', $disabled);
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. }
  7. /**
  8. * Checks if Composer is installed and accessible in the current environment.
  9. *
  1. $Qproducts->bindInt(':language_id', (int)$CLICSHOPPING_Language->getId());
  2. $Qproducts->execute();
  3. while ($Qproducts->fetch()) {
  4. if (MODE_B2B_B2C == 'True') {
  5. if (!in_array($Qproducts->valueInt('products_id'), $exclude)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. $Qprice = $CLICSHOPPING_Db->prepare('select customers_group_price,
  7. customers_group_id
  8. from :table_products_groups
  9. where products_id = :products_id
  1. $price_string = '';
  2. $sde = 0;
  3. //while(list($sdek,$sdev)=each($all_groups)){
  4. foreach ($all_groups as $sdek => $sdev) {
  5. if (!in_array($Qproducts->valueInt('products_id') . ":" . (int)$sdek, $exclude)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($sde)
  7. $price_string .= ' - ';
  8. $price_string .= $sdev . ' : ' . $CLICSHOPPING_Currencies->format(isset($product_prices[$sdek]) ? $product_prices[$sdek] : $Qproducts->valueDecimal('products_price'));
  9. $sde = 1;
  10. }
  1. // Ajouter VISITOR_NAME . ': ' . $CLICSHOPPING_Currencies->format($Qproducts->valueDecimal('products_price')) pour permettre d'afficher le prix des clients qui ne font pas partie d'un groupe B2B(
  2. $select_string .= '<option value="' . $Qproducts->valueInt('products_id') . '">' . HTML::outputProtected($Qproducts->value('products_name')) . ' (' . CLICSHOPPING::getDef('visitor_name') . ': ' . $CLICSHOPPING_Currencies->format($Qproducts->valueDecimal('products_price')) . ' - ' . $price_string . ')</option>';
  3. }
  4. } else {
  5. if (!in_array($Qproducts->valueInt('products_id'), $exclude)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. $select_string .= '<option value="' . $Qproducts->valueInt('products_id') . '">' . HTML::outputProtected($Qproducts->value('products_name')) . ' (' . $CLICSHOPPING_Currencies->format($Qproducts->valueDecimal('products_price')) . ')</option>';
  7. }
  8. }
  9. // ####### END #######
  1. {
  2. if (is_dir($source) === true) {
  3. $files = new RecursiveIteratorIterator(new RecursiveDirectoryIterator($source), RecursiveIteratorIterator::CHILD_FIRST);
  4. foreach ($files as $file) {
  5. if (in_array($file->getBasename(), array('.', '..')) !== true) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if ($file->isDir() === true) {
  7. rmdir($file->getPathName());
  8. } elseif (($file->isFile() === true) || ($file->isLink() === true)) {
  9. unlink($file->getPathname());
  10. }
  1. $fileTypes = ['php']; // Create an array of file types
  2. $found = []; // Traverse the folder, and add filename to $found array if type matches
  3. foreach ($contents as $item) {
  4. $fileInfo = pathinfo($item);
  5. if (array_key_exists('extension', $fileInfo) && in_array($fileInfo['extension'], $fileTypes)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. $found[] = $item;
  7. }
  8. }
  9. if ($found) { // Check the $found array is not empty
  1. $QpaymentsNotAllowed->execute();
  2. $payments_not_allowed = $QpaymentsNotAllowed->fetch();
  3. $payments_unallowed = explode(",", $payments_not_allowed['group_payment_unallowed']);
  4. $clearance = (in_array($pay_check, $payments_unallowed)) ? true : false;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  5. } elseif ($CLICSHOPPING_Customer->isLoggedOn()) {
  6. $clearance = true;
  7. } else {
  8. $clearance = false;
  1. $Qpayments->execute();
  2. $payments_not_allowed = $Qpayments->fetch();
  3. $payments_unallowed = explode(",", $payments_not_allowed['group_payment_unallowed']);
  4. $clearance = (!in_array($pay_check, $payments_unallowed)) ? true : false;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  5. return $clearance;
  6. }
  7. }
  1. $QshippingNotAllowed->execute();
  2. $shipping_not_allowed = $QshippingNotAllowed->fetch();
  3. $shipping_unallowed = explode(",", $shipping_not_allowed['group_shipping_unallowed']);
  4. $shipping_clearance = (in_array($shipping_check, $shipping_unallowed)) ? true : false;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  5. } elseif ($CLICSHOPPING_Customer->isLoggedOn()) {
  6. $shipping_clearance = true;
  7. } else {
  8. $shipping_clearance = false;
  9. }
  1. $shipping_not_allowed = $Qshipping->fetch();
  2. if (!empty($shipping_not_allowed['group_payment_unallowed'])) {
  3. $shipping_unallowed = explode(',', $shipping_not_allowed['group_payment_unallowed']);
  4. $shipping_clearance = (!in_array($shipping_check, $shipping_unallowed)) ? true : false;
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  5. } else {
  6. $shipping_clearance = false;
  7. }
  8. return $shipping_clearance;
  1. $string = '';
  2. if (is_array($array) && !empty($array)) {
  3. foreach ($array as $key => $value) {
  4. if (!in_array($key, $exclude)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  5. $string .= $key . '=' . $value . '&';
  6. }
  7. }
  8. $string = substr($string, 0, -1);
  1. $Qglobal->execute();
  2. $global = $Qglobal->fetch();
  3. if (isset($_POST['action']) && ($_POST['action'] == 'process') && isset($_POST['formid']) && ($_POST['formid'] === $_SESSION['sessiontoken'])) {
  4. if (isset($_POST['product_global']) && is_numeric($_POST['product_global']) && in_array($_POST['product_global'], ['0', '1'])) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  5. $product_global = (int)$_POST['product_global'];
  6. } else {
  7. $product_global = 0;
  8. }
  1. } elseif (count($products) > 0) {
  2. $products_parsed = [];
  3. foreach ($products as $value) {
  4. if (is_numeric($value) && !in_array($value, $products_parsed)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  5. $products_parsed[] = $value;
  6. }
  7. }
  8. if (count($products_parsed) > 0) {
  1. if (defined('MODULE_PAYMENT_INSTALLED') && !is_null(MODULE_PAYMENT_INSTALLED)) {
  2. $this->modules = explode(';', MODULE_PAYMENT_INSTALLED);
  3. $include_modules = [];
  4. if ((!is_null($module)) && (in_array($module . '.' . substr(CLICSHOPPING::getIndex(), (strrpos(CLICSHOPPING::getIndex(), '.') + 1)), $this->modules, true) || in_array($module, $this->modules))) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  5. $this->selected_module = $module;
  6. if (str_contains($module, '\\')) {
  7. $class = Apps::getModuleClass($module, 'Payment');
  1. if (($this->getCountPaymentModules() == 1) && (!isset($_SESSION['payment']) || ($_SESSION['payment'] != $include_modules[0]['class']))) {
  2. $_SESSION['payment'] = $include_modules[0]['class'];
  3. }
  4. if ((!is_null($module)) && (in_array($module . '.' . substr(CLICSHOPPING::getIndex(), (strrpos(CLICSHOPPING::getIndex(), '.') + 1)), $this->modules, true) || in_array($module, $this->modules))) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  5. if (str_contains($module, '\\')) {
  6. $CLICSHOPPING_PM = Registry::get('Payment_' . str_replace('\\', '_', $module));
  7. if (isset($CLICSHOPPING_PM->form_action_url)) {
  8. /**
  1. $code = $vendor . '\\' . $app . '\\' . $module;
  2. }
  3. }
  4. if (isset($code) && (in_array($code . '.' . substr(CLICSHOPPING::getIndex(), (strrpos(CLICSHOPPING::getIndex(), '.') + 1)), $this->modules) || in_array($code, $this->modules))) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  5. if (str_contains($code, '\\')) {
  6. $class = Apps::getModuleClass($code, 'Shipping');
  7. $include_modules[] = [
  8. 'class' => $code,
  1. include($this->_directoryIncludes . $this->_directoryModules . $group . DIRECTORY_SEPARATOR . $class . '.php');
  2. }
  3. }
  4. // exclude $modules_boxe and search if the modules exist
  5. if (is_numeric(array_search($group, $this->getReadModulesDefaultDirectories())) && $group != $modules_boxes) {
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. $result = array_search($group, $this->getReadModulesDefaultDirectories());
  7. if (!is_null($result)) {
  8. if (is_file($this->getPathDirectoryTemplateThema() . $this->_directoryModules . $group . DIRECTORY_SEPARATOR . $class . '.php')) {
  9. include($this->getPathDirectoryTemplateThema() . $this->_directoryModules . $group . DIRECTORY_SEPARATOR . $class . '.php');
  1. }
  2. }
  3. // exclude $modules_boxe and search if the modules exist
  4. if (is_numeric(array_search($group, $this->getReadModulesDefaultDirectories())) && $group != $modules_boxes) {
  5. $result = array_search($group, $this->getReadModulesDefaultDirectories());
    array_search() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if (!is_null($result)) {
  7. if (is_file($this->getPathDirectoryTemplateThema() . $this->_directoryModules . $group . DIRECTORY_SEPARATOR . $class . '.php')) {
  8. include($this->getPathDirectoryTemplateThema() . $this->_directoryModules . $group . DIRECTORY_SEPARATOR . $class . '.php');
  9. } elseif (is_file($this->getDefaultTemplateDirectory() . DIRECTORY_SEPARATOR . $this->_directoryModules . $group . DIRECTORY_SEPARATOR . $class . '.php')) {
  1. $currentParent = $newParentId;
  2. $visitedCategories = [];
  3. // Traverse up the parent chain to check for circular reference
  4. while ($currentParent !== 0) {
  5. if (in_array($currentParent, $visitedCategories)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. return true; // Already visited, indicates circular reference
  7. }
  8. if ($currentParent === $categoryId) {
  9. return true; // Found the original category in the parent chain
  1. // Validate numeric fields
  2. if (isset($data['suppliers_country_id']) && !is_numeric($data['suppliers_country_id'])) {
  3. $errors[] = 'Country ID must be numeric';
  4. }
  5. if (isset($data['suppliers_status']) && !in_array($data['suppliers_status'], [0, 1])) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. $errors[] = 'Supplier status must be 0 or 1';
  7. }
  8. if (isset($data['languages_id']) && !is_numeric($data['languages_id'])) {
  9. $errors[] = 'Language ID must be numeric';
  1. while ($file = $dir->read()) {
  2. if (!is_dir($backup_directory . $file)) {
  3. $ext = substr($file, strrpos($file, '.') + 1);
  4. if (in_array($ext, array('zip', 'sql', 'gz')) && !isset($contents[$ext])) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  5. $contents[$ext] = $file;
  6. if ($ext != 'sql') { // zip and gz (binaries) are prioritized over sql (plain text)
  7. break;
  8. }
  1. }
  2. } else {
  3. $products_attributes_image = '';
  4. }
  5. $checked = \is_array($selected_attributes) && \in_array($value['id'], $selected_attributes) ? ' checked' : '';
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by clicshopping
  6. $chk_id = 'chk_' . $QproductsOptionsName->valueInt('products_options_id') . '_' . $value['id'];
  7. $products_options_content_display .= '<div class="col-md-12">';
  8. $products_options_content_display .= '<span class="ModuleProductsInfoOptionsPullDownMenu">';
  9. $products_options_content_display .= '<div class="custom-control custom-checkbox">';
  1. foreach ($dir_content as $key => $content) {
  2. $path = $root_dir . DIRECTORY_SEPARATOR . $content;
  3. if (is_file($path) && is_readable($path)) {
  4. // skip ignored files
  5. if (!\in_array($content, $ignore_files)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  6. if (preg_match($ignore_regex, $content) == 0) {
  7. $content_chunks = explode(".", $content);
  8. $ext = $content_chunks[\count($content_chunks) - 1];
  9. // only include files with desired extensions
  10. if (\in_array($ext, $allow_extensions)) {
  1. if (!\in_array($content, $ignore_files)) {
  2. if (preg_match($ignore_regex, $content) == 0) {
  3. $content_chunks = explode(".", $content);
  4. $ext = $content_chunks[\count($content_chunks) - 1];
  5. // only include files with desired extensions
  6. if (\in_array($ext, $allow_extensions)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  7. // save file name with path
  8. $all_data[] = $path;
  9. }
  10. }
  11. }
  1. }
  2. }
  3. } // if content is a directory and readable, add path and name
  4. elseif (is_dir($path) && is_readable($path)) {
  5. // skip any ignored dirs
  6. if (!\in_array($content, $ignore_dirs)) {
    in_array() should be called with the third parameter set to true to enable strict comparison and avoid type juggling bugs.
    Time to fix: about 15 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  7. // recursive callback to open new directory
  8. $all_data = get_files($path, $all_data);
  9. }
  10. }
  11. } // end foreach

Your project should not use deprecated PHP features 4

More information: https://insight.symfony.com/what-we-analyse/php.use_deprecated_function

  1. $result = curl_exec($curl);
  2. if (empty($result)) {
  3. $info = curl_getinfo($curl);
  4. curl_close($curl);
    curl_close() has been deprecated in PHP 8.5 and will be removed from PHP in the next major version.
    Last edited by ClicShopping
  5. } else {
  6. $info = 'error';
  7. }
  8. return $info;
  1. $result = curl_exec($curl);
  2. if (empty($result)) {
  3. $info = curl_getinfo($curl);
  4. curl_close($curl);
    curl_close() has been deprecated in PHP 8.5 and will be removed from PHP in the next major version.
    Last edited by ClicShopping
  5. } else {
  6. $info = 'error';
  7. }
  8. return $info;
  1. $result = curl_exec($curl);
  2. if (empty($result)) {
  3. $info = curl_getinfo($curl);
  4. curl_close($curl);
    curl_close() has been deprecated in PHP 8.5 and will be removed from PHP in the next major version.
    Last edited by ClicShopping
  5. } else {
  6. $info = 'error';
  7. }
  8. return $info;
  1. $result = curl_exec($curl);
  2. if (empty($result)) {
  3. $info = curl_getinfo($curl);
  4. curl_close($curl);
    curl_close() has been deprecated in PHP 8.5 and will be removed from PHP in the next major version.
    Last edited by ClicShopping
  5. } else {
  6. $info = 'error';
  7. }
  8. return $info;

Mutable DateTime should be avoided in favor of DateTimeImmutable 3

More information: https://insight.symfony.com/what-we-analyse/php.prefer_date_time_immutable

  1. if (!empty($_POST['schdate'])) {
  2. $schdate = HTML::sanitize($_POST['schdate']);
  3. $date1 = new \DateTime(date('Y-m-d'));
  4. $date2 = new \DateTime($schdate);
    Use DateTimeImmutable instead of DateTime.
    Time to fix: about 30 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  5. if ($date1 < $date2) {
  6. $status = 0;
  7. }
  8. } else {
  1. if (!empty($_POST['schdate'])) {
  2. $schdate = HTML::sanitize($_POST['schdate']);
  3. $date1 = new \DateTime(date('Y-m-d'));
  4. $date2 = new \DateTime($schdate);
    Use DateTimeImmutable instead of DateTime.
    Time to fix: about 30 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  5. if ($date1 < $date2) {
  6. $status = 0;
  7. }
  8. } else {
  1. </div>
  2. <?php
  3. if ((ACCOUNT_DOB == 'true' && ($CLICSHOPPING_Customer->getCustomersGroupID() == 0)) || (ACCOUNT_DOB_PRO == 'true' && ($CLICSHOPPING_Customer->getCustomersGroupID() != 0))) {
  4. if (!empty($customers_dob)) {
  5. $customers_dob = DateTime::toShort($customers_dob);
  6. $dateObj = new \DateTime($customers_dob);
    Use DateTimeImmutable instead of DateTime.
    Time to fix: about 30 minutes
    Read doc Open Issue Permalink Copy Prompt
    Last edited by ClicShopping
  7. $customers_dob = $dateObj->format('Y-m-d');
  8. } else {
  9. $customers_dob = null;
  10. }
  11. ?>