コード例 #1
0
ファイル: Web.cs プロジェクト: wowngasb/peachpie
 /// <summary>
 /// Parses a string as if it were the query string passed via an URL and sets variables in the
 /// current scope.
 /// </summary>
 /// <param name="locals">Array of local variables passed from runtime, will be filled with parsed variables. Must not be <c>null</c>.</param>
 /// <param name="str">The string to parse.</param>
 public static void parse_str(QueryValue <LocalVariables> locals, string str)
 {
     if (!string.IsNullOrEmpty(str))
     {
         UriUtils.ParseQuery(str, locals.Value.Locals.AddVariable);
     }
 }
コード例 #2
0
ファイル: Web.cs プロジェクト: priioom/peachpie
 /// <summary>
 /// Parses a string as if it were the query string passed via an URL and sets variables in the
 /// current scope.
 /// </summary>
 /// <param name="locals">Array of local variables passed from runtime, will be filled with parsed variables. Must not be <c>null</c>.</param>
 /// <param name="str">The string to parse.</param>
 public static void parse_str([ImportValue(ImportValueAttribute.ValueSpec.Locals)] PhpArray locals, string str)
 {
     if (!string.IsNullOrEmpty(str))
     {
         UriUtils.ParseQuery(str, locals.AddVariable);
     }
 }
コード例 #3
0
        /// <summary>
        /// Parses a string as if it were the query string passed via an URL and sets variables in the
        /// current scope.
        /// </summary>
        /// <param name="locals">Array of local variables passed from runtime, will be filled with parsed variables. Must not be <c>null</c>.</param>
        /// <param name="str">The string to parse.</param>
        public static void parse_str([ImportLocals] PhpArray locals, string str)
        {
            Debug.Assert(locals != null);

            if (!string.IsNullOrEmpty(str))
            {
                UriUtils.ParseQuery(str, locals.AddVariable);
            }
        }
コード例 #4
0
 public static bool mb_parse_str(Context ctx, string encoded_string)
 {
     UriUtils.ParseQuery(encoded_string, ctx.Globals.AddVariable);
     return(true);
 }
コード例 #5
0
 public static bool mb_parse_str(string encoded_string, out PhpArray array)
 {
     array = new PhpArray();
     UriUtils.ParseQuery(encoded_string, array.AddVariable);
     return(true);
 }