PHP函数从数组构建查询字符串 [英] PHP function to build query string from array

查看:83
本文介绍了PHP函数从数组构建查询字符串的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在寻找PHP函数的名称,以从键值对数组构建查询字符串.请注意,我正在寻找内置的PHP 函数来执行此操作,而不是自制程序(这一切都是Google搜索似乎返回的).有一个,我只是不记得它的名字或在php.net上找到它. IIRC的名称不是那么直观.

I'm looking for the name of the PHP function to build a query string from an array of key value pairs. Please note, I am looking for the built in PHP function to do this, not a homebrew one (that's all a google search seems to return). There is one, I just can't remember its name or find it on php.net. IIRC its name isn't that intuitive.

推荐答案

您在寻找

You're looking for http_build_query().

这篇关于PHP函数从数组构建查询字符串的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆