Mark old, rarely used, and/or not recommended functions as deprecated

This commit is contained in:
Kijin Sung 2022-08-15 18:31:10 +09:00
parent fdd3f4bc1e
commit d93027078e
2 changed files with 18 additions and 1 deletions

View file

@ -557,6 +557,7 @@ function tobool($input)
/**
* Counts members of an array or an object.
*
* @deprecated
* @param mixed $array_or_object
* @return int
*/

View file

@ -705,6 +705,7 @@ function debugPrint($entry = null)
}
/**
* @deprecated
* @param string $type query, trigger
* @param float $elapsed_time
* @param object $obj
@ -715,6 +716,7 @@ function writeSlowlog($type, $elapsed_time, $obj)
}
/**
* @deprecated
* @param void
*/
function flushSlowlog()
@ -773,6 +775,7 @@ function getDestroyXeVars($vars)
/**
* Legacy error handler
*
* @deprecated
* @param int $errno
* @param string $errstr
* @param string $file
@ -804,12 +807,13 @@ function getNumberingPath($no, $size = 3)
/**
* Decode the URL in Korean
*
* @deprecated
* @param string $str The url
* @return string
*/
function url_decode($str)
{
return htmlspecialchars(utf8RawUrlDecode($str), null, 'UTF-8');
return escape(utf8RawUrlDecode($str));
}
/**
@ -826,6 +830,7 @@ function removeHackTag($content)
/**
* HTMLPurifier wrapper (Deprecated)
*
* @deprecated
* @param string &$content Target content
* @return string
*/
@ -837,6 +842,7 @@ function purifierHtml(&$content)
/**
* Check xmp tag (Deprecated)
*
* @deprecated
* @param string $content Target content
* @return string
*/
@ -848,6 +854,7 @@ function checkXmpTag($content)
/**
* Block widget code (Deprecated)
*
* @deprecated
* @param string $content Taget content
* @return string
**/
@ -859,6 +866,7 @@ function blockWidgetCode($content)
/**
* Remove src hack (Deprecated)
*
* @deprecated
* @param array $match
* @return string
*/
@ -870,6 +878,7 @@ function removeSrcHack($match)
/**
* Check uploaded file (Deprecated)
*
* @deprecated
* @param string $file Taget file path
* @return bool
*/
@ -897,6 +906,7 @@ if(!function_exists('hexrgb'))
* provides backward compatibility for zero board4 which uses old_password() of mysql 4.1 earlier versions.
* the function implemented by referring to the source codes of password.c file in mysql
*
* @deprecated
* @param string $password
* @return string
*/
@ -908,6 +918,7 @@ function mysql_pre4_hash_password($password)
/**
* Return the requested script path
*
* @deprecated
* @return string
*/
function getScriptPath()
@ -918,6 +929,7 @@ function getScriptPath()
/**
* Return the requested script path
*
* @deprecated
* @return string
*/
function getRequestUriByServerEnviroment()
@ -930,6 +942,7 @@ function getRequestUriByServerEnviroment()
* Function converts an Javascript escaped string back into a string with specified charset (default is UTF-8).
* Modified function from http://pure-essence.net/stuff/code/utf8RawUrlDecode.phps
*
* @deprecated
* @param string $source
* @return string
*/
@ -943,6 +956,7 @@ function utf8RawUrlDecode($source)
/**
* Returns utf-8 string of given code
*
* @deprecated
* @param int $num
* @return string
*/
@ -981,6 +995,7 @@ function detectUTF8($string, $return_convert = FALSE, $urldecode = TRUE)
/**
* get json encoded string of data
*
* @deprecated
* @param mixed $data
* @return string
*/
@ -1042,6 +1057,7 @@ function stripEmbedTagForAdmin(&$content, $writer_member_srl)
/**
* Require pear
*
* @deprecated
* @return void
*/
function requirePear()