uTools-Manuals/docs/php/mb_parse_str.html
2019-04-08 23:22:26 +08:00

85 lines
3.1 KiB
HTML
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<title>解析 GET/POST/COOKIE 数据并设置全局变量</title>
</head>
<body class="docs"><div id="layout">
<div id="layout-content"><div id="function.mb-parse-str" class="refentry">
<div class="refnamediv">
<h1 class="refname">mb_parse_str</h1>
<p class="verinfo">(PHP 4 &gt;= 4.0.6, PHP 5, PHP 7)</p><p class="refpurpose"><span class="refname">mb_parse_str</span> &mdash; <span class="dc-title">解析 GET/POST/COOKIE 数据并设置全局变量</span></p>
</div>
<div class="refsect1 description" id="refsect1-function.mb-parse-str-description">
<h3 class="title">说明</h3>
<div class="methodsynopsis dc-description">
<span class="methodname"><strong>mb_parse_str</strong></span>
( <span class="methodparam"><span class="type">string</span> <code class="parameter">$encoded_string</code></span>
[, <span class="methodparam"><span class="type">array</span> <code class="parameter reference">&$result</code></span>
] ) : <span class="type">bool</span></div>
<p class="para rdfs-comment">
解析 GET/POST/COOKIE 数据并设置全局变量。
由于 PHP 不提供原始 POST/COOKIE 数据,目前它仅能够用于 GET 数据。
它解析了 URL 编码过的数据,检测其编码,并转换编码为内部编码,然后设置其值为 <span class="type"><a href="language.types.array.html" class="type array">array</a></span><code class="parameter">result</code> 或者全局变量。
</p>
</div>
<div class="refsect1 parameters" id="refsect1-function.mb-parse-str-parameters">
<h3 class="title">参数</h3>
<p class="para">
<dl>
<dt>
<code class="parameter">encoded_string</code></dt>
<dd>
<p class="para">
URL 编码过的数据。
</p>
</dd>
<dt>
<code class="parameter">result</code></dt>
<dd>
<p class="para">
一个 <span class="type"><a href="language.types.array.html" class="type array">array</a></span>,包含解码过的、编码转换后的值。
</p>
</dd>
</dl>
</p>
</div>
<div class="refsect1 returnvalues" id="refsect1-function.mb-parse-str-returnvalues">
<h3 class="title">返回值</h3>
<p class="para">
成功时返回 <strong><code>TRUE</code></strong> 或者在失败时返回 <strong><code>FALSE</code></strong>
</p>
</div>
<div class="refsect1 seealso" id="refsect1-function.mb-parse-str-seealso">
<h3 class="title">参见</h3>
<p class="para">
<ul class="simplelist">
<li class="member"><span class="function"><a href="mb_detect_order.html" class="function" rel="rdfs-seeAlso">mb_detect_order()</a> - 设置/获取 字符编码的检测顺序</span></li>
<li class="member"><span class="function"><a href="mb_internal_encoding.html" class="function" rel="rdfs-seeAlso">mb_internal_encoding()</a> - 设置/获取内部字符编码</span></li>
</ul>
</p>
</div>
</div></div></div></body></html>