Fix doc blocks
This commit is contained in:
parent
05e78b2778
commit
c726d423fe
@ -76,7 +76,8 @@ function PMA_pow($base, $exp, $use_function = false)
|
||||
* @param string $icon name of icon file
|
||||
* @param string $alternate alternate text
|
||||
* @param boolean $force_text whether to force alternate text to be displayed
|
||||
* @param boolean $noSprite If true, the image source will be not replaced with a CSS Sprite
|
||||
* @param boolean $noSprite If true, the image source will be not replaced
|
||||
* with a CSS Sprite
|
||||
*
|
||||
* @return html img tag
|
||||
*/
|
||||
@ -153,13 +154,13 @@ function PMA_generateHiddenMaxFileSize($max_size)
|
||||
* Add slashes before "'" and "\" characters so a value containing them can
|
||||
* be used in a sql comparison.
|
||||
*
|
||||
* @param string $a_string the string to slash
|
||||
* @param bool $is_like whether the string will be used in a 'LIKE' clause
|
||||
* (it then requires two more escaped sequences) or not
|
||||
* @param bool $crlf whether to treat cr/lfs as escape-worthy entities
|
||||
* (converts \n to \\n, \r to \\r)
|
||||
* @param bool $php_code whether this function is used as part of the
|
||||
* "Create PHP code" dialog
|
||||
* @param string $a_string the string to slash
|
||||
* @param bool $is_like whether the string will be used in a 'LIKE' clause
|
||||
* (it then requires two more escaped sequences) or not
|
||||
* @param bool $crlf whether to treat cr/lfs as escape-worthy entities
|
||||
* (converts \n to \\n, \r to \\r)
|
||||
* @param bool $php_code whether this function is used as part of the
|
||||
* "Create PHP code" dialog
|
||||
*
|
||||
* @return string the slashed string
|
||||
*
|
||||
@ -210,7 +211,7 @@ function PMA_escape_mysql_wildcards($name)
|
||||
* removes slashes before "_" and "%" characters
|
||||
* Note: This function does not unescape backslashes!
|
||||
*
|
||||
* @param string $name the string to escape
|
||||
* @param string $name the string to escape
|
||||
*
|
||||
* @return string the escaped string
|
||||
*
|
||||
@ -262,7 +263,6 @@ function PMA_unQuote($quoted_string, $quote = null)
|
||||
/**
|
||||
* format sql strings
|
||||
*
|
||||
* @todo move into PMA_Sql
|
||||
* @param mixed $parsed_sql pre-parsed SQL structure
|
||||
* @param string $unparsed_sql raw SQL string
|
||||
*
|
||||
@ -272,7 +272,7 @@ function PMA_unQuote($quoted_string, $quote = null)
|
||||
* @global boolean whether the current statement is a multiple one or not
|
||||
*
|
||||
* @access public
|
||||
*
|
||||
* @todo move into PMA_Sql
|
||||
*/
|
||||
function PMA_formatSql($parsed_sql, $unparsed_sql = '')
|
||||
{
|
||||
@ -419,7 +419,7 @@ function PMA_showMySQLDocu($chapter, $link, $big_icon = false, $anchor = '', $ju
|
||||
/**
|
||||
* Displays a link to the phpMyAdmin documentation
|
||||
*
|
||||
* @param string $anchor anchor in documentation
|
||||
* @param string $anchor anchor in documentation
|
||||
*
|
||||
* @return string the html link
|
||||
*
|
||||
@ -437,7 +437,7 @@ function PMA_showDocu($anchor)
|
||||
/**
|
||||
* Displays a link to the PHP documentation
|
||||
*
|
||||
* @param string $target anchor in documentation
|
||||
* @param string $target anchor in documentation
|
||||
*
|
||||
* @return string the html link
|
||||
*
|
||||
@ -457,9 +457,9 @@ function PMA_showPHPDocu($target)
|
||||
/**
|
||||
* returns HTML for a footnote marker and add the messsage to the footnotes
|
||||
*
|
||||
* @param string $message the error message
|
||||
* @param bool $bbcode
|
||||
* @param string $type
|
||||
* @param string $message the error message
|
||||
* @param bool $bbcode
|
||||
* @param string $type message types
|
||||
*
|
||||
* @return string html code for a footnote marker
|
||||
*
|
||||
@ -500,11 +500,11 @@ function PMA_showHint($message, $bbcode = false, $type = 'notice')
|
||||
/**
|
||||
* Displays a MySQL error message in the right frame.
|
||||
*
|
||||
* @param string $error_message the error message
|
||||
* @param string $the_query the sql query that failed
|
||||
* @param bool $is_modify_link whether to show a "modify" link or not
|
||||
* @param string $back_url the "back" link url (full path is not required)
|
||||
* @param bool $exit EXIT the page?
|
||||
* @param string $error_message the error message
|
||||
* @param string $the_query the sql query that failed
|
||||
* @param bool $is_modify_link whether to show a "modify" link or not
|
||||
* @param string $back_url the "back" link url (full path is not required)
|
||||
* @param bool $exit EXIT the page?
|
||||
*
|
||||
* @global string the curent table
|
||||
* @global string the current db
|
||||
@ -650,10 +650,10 @@ function PMA_mysqlDie($error_message = '', $the_query = '',
|
||||
/**
|
||||
* returns array with tables of given db with extended information and grouped
|
||||
*
|
||||
* @param string $db name of db
|
||||
* @param string $tables name of tables
|
||||
* @param integer $limit_offset list offset
|
||||
* @param int|bool $limit_count max tables to return
|
||||
* @param string $db name of db
|
||||
* @param string $tables name of tables
|
||||
* @param integer $limit_offset list offset
|
||||
* @param int|bool $limit_count max tables to return
|
||||
*
|
||||
* @return array (recursive) grouped table list
|
||||
*/
|
||||
@ -782,10 +782,10 @@ function PMA_getTableList($db, $tables = null, $limit_offset = 0, $limit_count =
|
||||
*
|
||||
* </code>
|
||||
*
|
||||
* @param mixed $a_name the database, table or field name to "backquote"
|
||||
* or array of it
|
||||
* @param boolean $do_it a flag to bypass this function (used by dump
|
||||
* functions)
|
||||
* @param mixed $a_name the database, table or field name to "backquote"
|
||||
* or array of it
|
||||
* @param boolean $do_it a flag to bypass this function (used by dump
|
||||
* functions)
|
||||
*
|
||||
* @return mixed the "backquoted" database, table or field name
|
||||
*
|
||||
@ -880,10 +880,10 @@ if (typeof(window.parent) != 'undefined'
|
||||
* displays the message and the query
|
||||
* usually the message is the result of the query executed
|
||||
*
|
||||
* @param string $message the message to display
|
||||
* @param string $sql_query the query to display
|
||||
* @param string $type the type (level) of the message
|
||||
* @param boolean $is_view is this a message after a VIEW operation?
|
||||
* @param string $message the message to display
|
||||
* @param string $sql_query the query to display
|
||||
* @param string $type the type (level) of the message
|
||||
* @param boolean $is_view is this a message after a VIEW operation?
|
||||
*
|
||||
* @return string
|
||||
*
|
||||
@ -1271,7 +1271,8 @@ function PMA_profilingSupported()
|
||||
/**
|
||||
* Displays a form with the Profiling checkbox
|
||||
*
|
||||
* @param string $sql_query
|
||||
* @param string $sql_query sql query
|
||||
*
|
||||
* @access public
|
||||
*/
|
||||
function PMA_profilingCheckbox($sql_query)
|
||||
@ -1290,9 +1291,9 @@ function PMA_profilingCheckbox($sql_query)
|
||||
/**
|
||||
* Formats $value to byte view
|
||||
*
|
||||
* @param double $value the value to format
|
||||
* @param int $limes the sensitiveness
|
||||
* @param int $comma the number of decimals to retain
|
||||
* @param double $value the value to format
|
||||
* @param int $limes the sensitiveness
|
||||
* @param int $comma the number of decimals to retain
|
||||
*
|
||||
* @return array the formatted value and its unit
|
||||
*
|
||||
@ -1346,7 +1347,7 @@ function PMA_formatByteDown($value, $limes = 6, $comma = 0)
|
||||
/**
|
||||
* Changes thousands and decimal separators to locale specific values.
|
||||
*
|
||||
* @param $value
|
||||
* @param string $value the value
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
@ -1376,13 +1377,13 @@ function PMA_localizeNumber($value)
|
||||
* echo PMA_formatNumber(0.003, 3, 3); // 0.003
|
||||
* echo PMA_formatNumber(0.00003, 3, 2); // 0.03 m
|
||||
* echo PMA_formatNumber(0, 6); // 0
|
||||
*
|
||||
* </code>
|
||||
* @param double $value the value to format
|
||||
* @param integer $digits_left number of digits left of the comma
|
||||
* @param integer $digits_right number of digits right of the comma
|
||||
* @param boolean $only_down do not reformat numbers below 1
|
||||
* @param boolean $noTrailingZero removes trailing zeros right of the comma (default: true)
|
||||
*
|
||||
* @param double $value the value to format
|
||||
* @param integer $digits_left number of digits left of the comma
|
||||
* @param integer $digits_right number of digits right of the comma
|
||||
* @param boolean $only_down do not reformat numbers below 1
|
||||
* @param boolean $noTrailingZero removes trailing zeros right of the comma (default: true)
|
||||
*
|
||||
* @return string the formatted value and its unit
|
||||
*
|
||||
@ -1474,7 +1475,7 @@ function PMA_formatNumber($value, $digits_left = 3, $digits_right = 0, $only_dow
|
||||
/**
|
||||
* Returns the number of bytes when a formatted size is given
|
||||
*
|
||||
* @param string $formatted_size the size expression (for example 8MB)
|
||||
* @param string $formatted_size the size expression (for example 8MB)
|
||||
*
|
||||
* @return integer The numerical part of the expression (for example 8)
|
||||
*/
|
||||
@ -1495,8 +1496,8 @@ function PMA_extractValueFromFormattedSize($formatted_size)
|
||||
/**
|
||||
* Writes localised date
|
||||
*
|
||||
* @param string $timestamp the current timestamp
|
||||
* @param string $format format
|
||||
* @param string $timestamp the current timestamp
|
||||
* @param string $format format
|
||||
*
|
||||
* @return string the formatted date
|
||||
*
|
||||
@ -1565,8 +1566,8 @@ function PMA_localisedDate($timestamp = -1, $format = '')
|
||||
* returns a tab for tabbed navigation.
|
||||
* If the variables $link and $args ar left empty, an inactive tab is created
|
||||
*
|
||||
* @param array $tab array with all options
|
||||
* @param array $url_params
|
||||
* @param array $tab array with all options
|
||||
* @param array $url_params
|
||||
*
|
||||
* @return string html code for one tab, a link if valid otherwise a span
|
||||
*
|
||||
@ -1666,8 +1667,8 @@ function PMA_generate_html_tab($tab, $url_params = array(), $base_dir='')
|
||||
/**
|
||||
* returns html-code for a tab navigation
|
||||
*
|
||||
* @param array $tabs one element per tab
|
||||
* @param string $url_params
|
||||
* @param array $tabs one element per tab
|
||||
* @param string $url_params
|
||||
*
|
||||
* @return string html-code for tab-navigation
|
||||
*/
|
||||
@ -1695,14 +1696,14 @@ function PMA_generate_html_tabs($tabs, $url_params, $base_dir='')
|
||||
* Displays a link, or a button if the link's URL is too large, to
|
||||
* accommodate some browsers' limitations
|
||||
*
|
||||
* @param string $url the URL
|
||||
* @param string $message the link message
|
||||
* @param mixed $tag_params string: js confirmation
|
||||
* array: additional tag params (f.e. style="")
|
||||
* @param boolean $new_form we set this to false when we are already in
|
||||
* a form, to avoid generating nested forms
|
||||
* @param boolean $strip_img
|
||||
* @param string $target
|
||||
* @param string $url the URL
|
||||
* @param string $message the link message
|
||||
* @param mixed $tag_params string: js confirmation
|
||||
* array: additional tag params (f.e. style="")
|
||||
* @param boolean $new_form we set this to false when we are already in
|
||||
* a form, to avoid generating nested forms
|
||||
* @param boolean $strip_img whether to strip the image
|
||||
* @param string $target target
|
||||
*
|
||||
* @return string the results to be echoed or saved in an array
|
||||
*/
|
||||
@ -1822,7 +1823,8 @@ function PMA_linkOrButton($url, $message, $tag_params = array(),
|
||||
/**
|
||||
* Splits a URL string by parameter
|
||||
*
|
||||
* @param string $url the URL
|
||||
* @param string $url the URL
|
||||
*
|
||||
* @return array the parameter/value pairs, for example [0] db=sakila
|
||||
*/
|
||||
function PMA_splitURLQuery($url) {
|
||||
@ -1844,7 +1846,7 @@ function PMA_splitURLQuery($url) {
|
||||
/**
|
||||
* Returns a given timespan value in a readable format.
|
||||
*
|
||||
* @param int $seconds the timespan
|
||||
* @param int $seconds the timespan
|
||||
*
|
||||
* @return string the formatted value
|
||||
*/
|
||||
@ -1872,11 +1874,11 @@ function PMA_timespanFormat($seconds)
|
||||
* Fulfills todo-item
|
||||
* http://sf.net/tracker/?func=detail&aid=544361&group_id=23067&atid=377411
|
||||
*
|
||||
* @todo add a multibyte safe function PMA_STR_split()
|
||||
* @param string $string The string
|
||||
* @param string $Separator The Separator (defaults to "<br />\n")
|
||||
* @param string $string The string
|
||||
* @param string $Separator The Separator (defaults to "<br />\n")
|
||||
*
|
||||
* @access public
|
||||
* @todo add a multibyte safe function PMA_STR_split()
|
||||
*
|
||||
* @return string The flipped string
|
||||
*/
|
||||
@ -1920,16 +1922,17 @@ function PMA_flipstring($string, $Separator = "<br />\n")
|
||||
* Not sure we could use a strMissingParameter message here,
|
||||
* would have to check if the error message file is always available
|
||||
*
|
||||
* @todo use PMA_fatalError() if $die === true?
|
||||
* @param array $params The names of the parameters needed by the calling script.
|
||||
* @param bool $die Stop the execution?
|
||||
* (Set this manually to false in the calling script
|
||||
* until you know all needed parameters to check).
|
||||
* @param bool $request Whether to include this list in checking for special params.
|
||||
* @param array $params The names of the parameters needed by the calling script.
|
||||
* @param bool $die Stop the execution?
|
||||
* (Set this manually to false in the calling script
|
||||
* until you know all needed parameters to check).
|
||||
* @param bool $request Whether to include this list in checking for special params.
|
||||
*
|
||||
* @global string path to current script
|
||||
* @global boolean flag whether any special variable was required
|
||||
*
|
||||
* @access public
|
||||
* @todo use PMA_fatalError() if $die === true?
|
||||
*/
|
||||
function PMA_checkParameters($params, $die = true, $request = true)
|
||||
{
|
||||
@ -1972,11 +1975,11 @@ function PMA_checkParameters($params, $die = true, $request = true)
|
||||
/**
|
||||
* Function to generate unique condition for specified row.
|
||||
*
|
||||
* @param resource $handle current query result
|
||||
* @param integer $fields_cnt number of fields
|
||||
* @param array $fields_meta meta information about fields
|
||||
* @param array $row current row
|
||||
* @param boolean $force_unique generate condition only on pk or unique
|
||||
* @param resource $handle current query result
|
||||
* @param integer $fields_cnt number of fields
|
||||
* @param array $fields_meta meta information about fields
|
||||
* @param array $row current row
|
||||
* @param boolean $force_unique generate condition only on pk or unique
|
||||
*
|
||||
* @access public
|
||||
*
|
||||
@ -2123,12 +2126,12 @@ function PMA_getUniqueCondition($handle, $fields_cnt, $fields_meta, $row, $force
|
||||
/**
|
||||
* Generate a button or image tag
|
||||
*
|
||||
* @param string $button_name name of button element
|
||||
* @param string $button_class class of button element
|
||||
* @param string $image_name name of image element
|
||||
* @param string $text text to display
|
||||
* @param string $image image to display
|
||||
* @param string $value
|
||||
* @param string $button_name name of button element
|
||||
* @param string $button_class class of button element
|
||||
* @param string $image_name name of image element
|
||||
* @param string $text text to display
|
||||
* @param string $image image to display
|
||||
* @param string $value value
|
||||
*
|
||||
* @access public
|
||||
*/
|
||||
@ -2167,17 +2170,18 @@ function PMA_buttonOrImage($button_name, $button_class, $image_name, $text,
|
||||
/**
|
||||
* Generate a pagination selector for browsing resultsets
|
||||
*
|
||||
* @param int $rows Number of rows in the pagination set
|
||||
* @param int $pageNow current page number
|
||||
* @param int $nbTotalPage number of total pages
|
||||
* @param int $showAll If the number of pages is lower than this
|
||||
* variable, no pages will be omitted in pagination
|
||||
* @param int $sliceStart How many rows at the beginning should always be shown?
|
||||
* @param int $sliceEnd How many rows at the end should always be shown?
|
||||
* @param int $percent Percentage of calculation page offsets to hop to a next page
|
||||
* @param int $range Near the current page, how many pages should
|
||||
* be considered "nearby" and displayed as well?
|
||||
* @param string $prompt The prompt to display (sometimes empty)
|
||||
* @param int $rows Number of rows in the pagination set
|
||||
* @param int $pageNow current page number
|
||||
* @param int $nbTotalPage number of total pages
|
||||
* @param int $showAll If the number of pages is lower than this
|
||||
* variable, no pages will be omitted in pagination
|
||||
* @param int $sliceStart How many rows at the beginning should always be shown?
|
||||
* @param int $sliceEnd How many rows at the end should always be shown?
|
||||
* @param int $percent Percentage of calculation page offsets to hop to a
|
||||
* next page
|
||||
* @param int $range Near the current page, how many pages should
|
||||
* be considered "nearby" and displayed as well?
|
||||
* @param string $prompt The prompt to display (sometimes empty)
|
||||
*
|
||||
* @return string
|
||||
*
|
||||
@ -2267,15 +2271,16 @@ function PMA_pageselector($rows, $pageNow = 1, $nbTotalPage = 1,
|
||||
/**
|
||||
* Generate navigation for a list
|
||||
*
|
||||
* @todo use $pos from $_url_params
|
||||
* @param int $count number of elements in the list
|
||||
* @param int $pos current position in the list
|
||||
* @param array $_url_params url parameters
|
||||
* @param string $script script name for form target
|
||||
* @param string $frame target frame
|
||||
* @param int $max_count maximum number of elements to display from the list
|
||||
* @param int $count number of elements in the list
|
||||
* @param int $pos current position in the list
|
||||
* @param array $_url_params url parameters
|
||||
* @param string $script script name for form target
|
||||
* @param string $frame target frame
|
||||
* @param int $max_count maximum number of elements to display from the list
|
||||
*
|
||||
* @access public
|
||||
*
|
||||
* @todo use $pos from $_url_params
|
||||
*/
|
||||
function PMA_listNavigator($count, $pos, $_url_params, $script, $frame, $max_count)
|
||||
{
|
||||
@ -2357,7 +2362,7 @@ function PMA_listNavigator($count, $pos, $_url_params, $script, $frame, $max_cou
|
||||
*
|
||||
* </code>
|
||||
*
|
||||
* @param string $dir with wildcard for user
|
||||
* @param string $dir with wildcard for user
|
||||
*
|
||||
* @return string per user directory
|
||||
*/
|
||||
@ -2374,7 +2379,7 @@ function PMA_userDir($dir)
|
||||
/**
|
||||
* returns html code for db link to default db page
|
||||
*
|
||||
* @param string $database
|
||||
* @param string $database database
|
||||
*
|
||||
* @return string html link to default db page
|
||||
*/
|
||||
@ -2398,10 +2403,10 @@ function PMA_getDbLink($database = null)
|
||||
* Displays a lightbulb hint explaining a known external bug
|
||||
* that affects a functionality
|
||||
*
|
||||
* @param string $functionality localized message explaining the func.
|
||||
* @param string $component 'mysql' (eventually, 'php')
|
||||
* @param string $minimum_version of this component
|
||||
* @param string $bugref bug reference for this component
|
||||
* @param string $functionality localized message explaining the func.
|
||||
* @param string $component 'mysql' (eventually, 'php')
|
||||
* @param string $minimum_version of this component
|
||||
* @param string $bugref bug reference for this component
|
||||
*/
|
||||
function PMA_externalBug($functionality, $component, $minimum_version, $bugref)
|
||||
{
|
||||
@ -2417,6 +2422,8 @@ function PMA_externalBug($functionality, $component, $minimum_version, $bugref)
|
||||
* @param string $label label for checkbox
|
||||
* @param boolean $checked is it initially checked?
|
||||
* @param boolean $onclick should it submit the form on click?
|
||||
*
|
||||
* @return the HTML for the checkbox
|
||||
*/
|
||||
function PMA_display_html_checkbox($html_field_name, $label, $checked, $onclick)
|
||||
{
|
||||
@ -2433,6 +2440,8 @@ function PMA_display_html_checkbox($html_field_name, $label, $checked, $onclick)
|
||||
* @param boolean $line_break whether to add an HTML line break after a choice
|
||||
* @param boolean $escape_label whether to use htmlspecialchars() on label
|
||||
* @param string $class enclose each choice with a div of this class
|
||||
*
|
||||
* @return the HTML for the tadio buttons
|
||||
*/
|
||||
function PMA_display_html_radio($html_field_name, $choices, $checked_choice = '', $line_break = true, $escape_label = true, $class='')
|
||||
{
|
||||
@ -2460,11 +2469,12 @@ function PMA_display_html_radio($html_field_name, $choices, $checked_choice = ''
|
||||
/**
|
||||
* Generates and returns an HTML dropdown
|
||||
*
|
||||
* @param string $select_name
|
||||
* @param array $choices choices values
|
||||
* @param string $active_choice the choice to select by default
|
||||
* @param string $id id of the select element; can be different in case
|
||||
* the dropdown is present more than once on the page
|
||||
* @param string $select_name name for the select element
|
||||
* @param array $choices choices values
|
||||
* @param string $active_choice the choice to select by default
|
||||
* @param string $id id of the select element; can be different in case
|
||||
* the dropdown is present more than once on the page
|
||||
*
|
||||
* @return string
|
||||
*
|
||||
* @todo support titles
|
||||
@ -2489,8 +2499,8 @@ function PMA_generate_html_dropdown($select_name, $choices, $active_choice, $id)
|
||||
* controlling the slider; you have to generate the </div> yourself
|
||||
* after the sliding section.
|
||||
*
|
||||
* @param string $id the id of the <div> on which to apply the effect
|
||||
* @param string $message the message to show as a link
|
||||
* @param string $id the id of the <div> on which to apply the effect
|
||||
* @param string $message the message to show as a link
|
||||
*/
|
||||
function PMA_generate_slider_effect($id, $message)
|
||||
{
|
||||
@ -2511,13 +2521,14 @@ function PMA_generate_slider_effect($id, $message)
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates an AJAX sliding toggle button (or and equivalent form when AJAX is disabled)
|
||||
* Creates an AJAX sliding toggle button
|
||||
* (or and equivalent form when AJAX is disabled)
|
||||
*
|
||||
* @param string $action The URL for the request to be executed
|
||||
* @param string $select_name The name for the dropdown box
|
||||
* @param array $options An array of options (see rte_footer.lib.php)
|
||||
* @param string $callback A JS snippet to execute when the request is
|
||||
* successfully processed
|
||||
* @param string $action The URL for the request to be executed
|
||||
* @param string $select_name The name for the dropdown box
|
||||
* @param array $options An array of options (see rte_footer.lib.php)
|
||||
* @param string $callback A JS snippet to execute when the request is
|
||||
* successfully processed
|
||||
*
|
||||
* @return string HTML code for the toggle button
|
||||
*/
|
||||
@ -2602,8 +2613,8 @@ function PMA_clearUserCache()
|
||||
/**
|
||||
* Verifies if something is cached in the session
|
||||
*
|
||||
* @param string $var
|
||||
* @param int|true $server
|
||||
* @param string $var variable name
|
||||
* @param int|true $server server
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
@ -2618,8 +2629,8 @@ function PMA_cacheExists($var, $server = 0)
|
||||
/**
|
||||
* Gets cached information from the session
|
||||
*
|
||||
* @param string $var
|
||||
* @param int|true $server
|
||||
* @param string $var varibale name
|
||||
* @param int|true $server server
|
||||
*
|
||||
* @return mixed
|
||||
*/
|
||||
@ -2638,9 +2649,9 @@ function PMA_cacheGet($var, $server = 0)
|
||||
/**
|
||||
* Caches information in the session
|
||||
*
|
||||
* @param string $var
|
||||
* @param mixed $val
|
||||
* @param int|true $server
|
||||
* @param string $var variable name
|
||||
* @param mixed $val value
|
||||
* @param int|true $server server
|
||||
*
|
||||
* @return mixed
|
||||
*/
|
||||
@ -2655,8 +2666,8 @@ function PMA_cacheSet($var, $val = null, $server = 0)
|
||||
/**
|
||||
* Removes cached information from the session
|
||||
*
|
||||
* @param string $var
|
||||
* @param int|true $server
|
||||
* @param string $var variable name
|
||||
* @param int|true $server server
|
||||
*/
|
||||
function PMA_cacheUnset($var, $server = 0)
|
||||
{
|
||||
@ -2671,7 +2682,7 @@ function PMA_cacheUnset($var, $server = 0)
|
||||
* in MySQL a BIT field can be from 1 to 64 bits so we need this
|
||||
* function because in PHP, decbin() supports only 32 bits
|
||||
*
|
||||
* @param numeric $value coming from a BIT field
|
||||
* @param numeric $value coming from a BIT field
|
||||
* @param integer $length
|
||||
*
|
||||
* @return string the printable value
|
||||
@ -2689,7 +2700,7 @@ function PMA_printable_bit_value($value, $length)
|
||||
/**
|
||||
* Verifies whether the value contains a non-printable character
|
||||
*
|
||||
* @param string $value
|
||||
* @param string $value value
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
@ -2702,7 +2713,7 @@ function PMA_contains_nonprintable_ascii($value)
|
||||
* Converts a BIT type default value
|
||||
* for example, b'010' becomes 010
|
||||
*
|
||||
* @param string $bit_default_value
|
||||
* @param string $bit_default_value value
|
||||
*
|
||||
* @return string the converted value
|
||||
*/
|
||||
@ -2714,7 +2725,7 @@ function PMA_convert_bit_default_value($bit_default_value)
|
||||
/**
|
||||
* Extracts the various parts from a field type spec
|
||||
*
|
||||
* @param string $fieldspec
|
||||
* @param string $fieldspec Field specification
|
||||
*
|
||||
* @return array associative array containing type, spec_in_brackets
|
||||
* and possibly enum_set_values (another array)
|
||||
@ -2830,7 +2841,7 @@ function PMA_extractFieldSpec($fieldspec)
|
||||
/**
|
||||
* Verifies if this table's engine supports foreign keys
|
||||
*
|
||||
* @param string $engine
|
||||
* @param string $engine engine
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
@ -2847,7 +2858,7 @@ function PMA_foreignkey_supported($engine)
|
||||
/**
|
||||
* Replaces some characters by a displayable equivalent
|
||||
*
|
||||
* @param string $content
|
||||
* @param string $content content
|
||||
*
|
||||
* @return string the content with characters replaced
|
||||
*/
|
||||
@ -2864,8 +2875,9 @@ function PMA_replace_binary_contents($content)
|
||||
/**
|
||||
* Converts GIS data to Well Known Text format
|
||||
*
|
||||
* @param $data GIS data
|
||||
* @param $includeSRID Add SRID to the WKT
|
||||
* @param binary $data GIS data
|
||||
* @param bool $includeSRID Add SRID to the WKT
|
||||
*
|
||||
* @return GIS data in Well Know Text format
|
||||
*/
|
||||
function PMA_asWKT($data, $includeSRID = false) {
|
||||
@ -2889,7 +2901,7 @@ function PMA_asWKT($data, $includeSRID = false) {
|
||||
/**
|
||||
* If the string starts with a \r\n pair (0x0d0a) add an extra \n
|
||||
*
|
||||
* @param string $string
|
||||
* @param string $string string
|
||||
*
|
||||
* @return string with the chars replaced
|
||||
*/
|
||||
@ -2907,8 +2919,8 @@ function PMA_duplicateFirstNewline($string)
|
||||
* Get the action word corresponding to a script name
|
||||
* in order to display it as a title in navigation panel
|
||||
*
|
||||
* @param string $target a valid value for $cfg['LeftDefaultTabTable'], $cfg['DefaultTabTable']
|
||||
* or $cfg['DefaultTabDatabase']
|
||||
* @param string $target a valid value for $cfg['LeftDefaultTabTable'],
|
||||
* $cfg['DefaultTabTable'] or $cfg['DefaultTabDatabase']
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
@ -2934,9 +2946,10 @@ function PMA_getTitleForTarget($target)
|
||||
/**
|
||||
* Formats user string, expading @VARIABLES@, accepting strftime format string.
|
||||
*
|
||||
* @param string $string Text where to do expansion.
|
||||
* @param function $escape Function to call for escaping variable values.
|
||||
* @param array $updates Array with overrides for default parameters (obtained from GLOBALS).
|
||||
* @param string $string Text where to do expansion.
|
||||
* @param function $escape Function to call for escaping variable values.
|
||||
* @param array $updates Array with overrides for default parameters
|
||||
* (obtained from GLOBALS).
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
@ -3005,9 +3018,14 @@ function PMA_expandUserString($string, $escape = null, $updates = array())
|
||||
* function that generates a json output for an ajax request and ends script
|
||||
* execution
|
||||
*
|
||||
* @param PMA_Message|string $message message string containing the html of the message
|
||||
* @param bool $success success whether the ajax request was successfull
|
||||
* @param array $extra_data extra_data optional - any other data as part of the json request
|
||||
* @param PMA_Message|string $message message string containing the
|
||||
* html of the message
|
||||
* @param bool $success success whether the ajax request
|
||||
* was successfull
|
||||
* @param array $extra_data extra data optional -
|
||||
* any other data as part of the json request
|
||||
*
|
||||
* @return nothing
|
||||
*/
|
||||
function PMA_ajaxResponse($message, $success = true, $extra_data = array())
|
||||
{
|
||||
@ -3052,9 +3070,11 @@ function PMA_ajaxResponse($message, $success = true, $extra_data = array())
|
||||
}
|
||||
|
||||
/**
|
||||
* Display the form used to browse anywhere on the local server for the file to import
|
||||
* Display the form used to browse anywhere on the local server for a file to import
|
||||
*
|
||||
* @param $max_upload_size
|
||||
* @param string $max_upload_size maximum upload size
|
||||
*
|
||||
* @return nothing
|
||||
*/
|
||||
function PMA_browseUploadFile($max_upload_size)
|
||||
{
|
||||
@ -3070,8 +3090,10 @@ function PMA_browseUploadFile($max_upload_size)
|
||||
/**
|
||||
* Display the form used to select a file to import from the server upload directory
|
||||
*
|
||||
* @param $import_list
|
||||
* @param $uploaddir
|
||||
* @param array $import_list array of import types
|
||||
* @param string $uploaddir upload directory
|
||||
*
|
||||
* @return nothing
|
||||
*/
|
||||
function PMA_selectUploadFile($import_list, $uploaddir)
|
||||
{
|
||||
@ -3133,8 +3155,8 @@ function PMA_buildActionTitles()
|
||||
* $cfg['ColumnTypes'] and either returns an array (useful for quickly checking
|
||||
* if a datatype is supported) or an HTML snippet that creates a drop-down list.
|
||||
*
|
||||
* @param bool $html Whether to generate an html snippet or an array
|
||||
* @param string $selected The value to mark as selected in HTML mode
|
||||
* @param bool $html Whether to generate an html snippet or an array
|
||||
* @param string $selected The value to mark as selected in HTML mode
|
||||
*
|
||||
* @return mixed An HTML snippet or an array of datatypes.
|
||||
*
|
||||
@ -3197,12 +3219,18 @@ function PMA_getSupportedDatatypes($html = false, $selected = '')
|
||||
*
|
||||
* @return array list of datatypes
|
||||
*/
|
||||
|
||||
function PMA_unsupportedDatatypes() {
|
||||
$no_support_types = array();
|
||||
return $no_support_types;
|
||||
}
|
||||
|
||||
/**
|
||||
* Return GIS data types
|
||||
*
|
||||
* @param bool $upper_case whether to return values in upper case
|
||||
*
|
||||
* @return array GIS data types
|
||||
*/
|
||||
function PMA_getGISDatatypes($upper_case = false) {
|
||||
$gis_data_types = array('geometry',
|
||||
'point',
|
||||
@ -3226,6 +3254,8 @@ function PMA_getGISDatatypes($upper_case = false) {
|
||||
* Generates GIS data based on the string passed.
|
||||
*
|
||||
* @param string $gis_string GIS string
|
||||
*
|
||||
* @return GIS data enclosed in 'GeomFromText' function
|
||||
*/
|
||||
function PMA_createGISData($gis_string) {
|
||||
$gis_string = trim($gis_string);
|
||||
@ -3352,9 +3382,9 @@ function PMA_getGISFunctions($geom_type = null, $binary = true, $display = false
|
||||
/**
|
||||
* Creates a dropdown box with MySQL functions for a particular column.
|
||||
*
|
||||
* @param array $field Data about the column for which
|
||||
* to generate the dropdown
|
||||
* @param bool $insert_mode Whether the operation is 'insert'
|
||||
* @param array $field Data about the column for which
|
||||
* to generate the dropdown
|
||||
* @param bool $insert_mode Whether the operation is 'insert'
|
||||
*
|
||||
* @global array $cfg PMA configuration
|
||||
* @global array $analyzed_sql Analyzed SQL query
|
||||
@ -3458,12 +3488,11 @@ function PMA_getFunctionsForField($field, $insert_mode)
|
||||
* // 'CREATE ROUTINE' privilege or, if not, checks if the
|
||||
* // user has this privilege on database 'mydb'.
|
||||
*
|
||||
*
|
||||
* @param string $priv The privilege to check
|
||||
* @param mixed $db null, to only check global privileges
|
||||
* string, db name where to also check for privileges
|
||||
* @param mixed $tbl null, to only check global privileges
|
||||
* string, db name where to also check for privileges
|
||||
* @param string $priv The privilege to check
|
||||
* @param mixed $db null, to only check global privileges
|
||||
* string, db name where to also check for privileges
|
||||
* @param mixed $tbl null, to only check global privileges
|
||||
* string, db name where to also check for privileges
|
||||
*
|
||||
* @return bool
|
||||
*/
|
||||
|
||||
Loading…
Reference in New Issue
Block a user