PHP error

htmlentities(): Passing null to parameter #2 ($flags) of type int is deprecated

/media/shnoulle/data/www/master/assets/packages/kcfinder/core/class/browser.php(922)

910     protected function errorMsg($message, ?array $data=null) {
911         if (in_array($this->action, array("thumb", "upload", "download", "downloadDir")))
912             die($this->label($message, $data));
913         if (($this->action === null) || ($this->action == "browser"))
914             $this->backMsg($message, $data);
915         else {
916             $message = $this->label($message, $data);
917             die(json_encode(array('error' => $message)));
918         }
919     }
920 
921     protected function htmlData($str) {
922         return htmlentities((string) $str, null, strtoupper($this->charset));
923     }
924 }
925 
926 ?>

Stack Trace

#0
+
–
 /media/shnoulle/data/www/master/assets/packages/kcfinder/core/class/browser.php(922): htmlentities("limesurvey_group_66.lsg", null, "UTF-8")
917             die(json_encode(array('error' => $message)));
918         }
919     }
920 
921     protected function htmlData($str) {
922         return htmlentities((string) $str, null, strtoupper($this->charset));
923     }
924 }
925 
926 ?>
#1
+
–
 /media/shnoulle/data/www/master/assets/packages/kcfinder/core/class/browser.php(712): kcfinder\browser->htmlData("limesurvey_group_66.lsg")
707         $message = $this->checkUploadedFile($file);
708 
709         if ($message !== true) {
710             if (isset($file['tmp_name']))
711                 @unlink($file['tmp_name']);
712             return $this->htmlData($file['name']) . ": " . $message;
713         }
714 
715         $filename = $this->normalizeFilename($file['name']);
716         $target = "$dir/" . file::getInexistantFilename($filename, $dir);
717 
#2
+
–
 /media/shnoulle/data/www/master/assets/packages/kcfinder/core/class/browser.php(301): kcfinder\browser->moveUploadFile(array("name" => "limesurvey_group_66.lsg", "tmp_name" => "/tmp/phpmdECan", "error" => 0), "/media/shnoulle/data/www/master/upload/surveys/797994/images/")
296             $this->errorMsg("Cannot access or write to upload folder.");
297 
298         if (is_array($this->file['name'])) {
299             $return = array();
300             foreach ($this->file['name'] as $i => $name) {
301                 $return[] = $this->moveUploadFile(array(
302                     'name' => $name,
303                     'tmp_name' => $this->file['tmp_name'][$i],
304                     'error' => $this->file['error'][$i]
305                 ), $dir);
306             }
2026-10-21 09:58:13 nginx/1.26.3 Yii Framework/1.1.33-dev