Sponsored Content
The Lounge What is on Your Mind? How to encourage emerging users in forum to give better solution:? Post 302927458 by rbatte1 on Wednesday 3rd of December 2014 05:50:25 AM
Old 12-03-2014
I would agree that the system in place works well. There is the option to gift bits and while there is no trade-able value, the wonderful feeling one gets when receiving a gift is enough. Perhaps we could make that process more available, perhaps a Thanks+GiftBits or a Thanks+PM button, but then it has to be used properly rather than just being too easy and meaningless.

I'm not sure what I'm arguing for now, but perhaps there needs to be some limit on using them per user per week to give them proper kudos value.

As to the earlier quote regarding optimism versus pessimism:-
Quote:
You can see a cup of milk which has some milk in it as a half filled or you can see it is half empty.
.... one could argue that someone has bought a cup that is too large. Smilie


Just my thoughts,
Robin
This User Gave Thanks to rbatte1 For This Post:
 

2 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Can any body give me a solution to this...

Hi friends.. I am using the below command to search few files from many folders which is under one folder.. i mean let say the path is A/B/C...and inside C...i have 1-10 folder... the below command is working fine.... for i in 1 3 5 7; do find /A/B/C/${i} -name "*.txt" -o -name "*.csv"... (9 Replies)
Discussion started by: sapan123
9 Replies

2. What is on Your Mind?

Regarding thoughts for encourage more users to post/participate on UNIX.com site.

Hello All, Greetings!! Have a thought about how could we encourage more users to post and participate more on UNIX.com(because more we get questions, more we learn more), few are my ideas which I am posting feel free to add/edit more ideas in here. Keeping this as a POLL too. I- Allow... (10 Replies)
Discussion started by: RavinderSingh13
10 Replies
HTTP_BUILD_QUERY(3)							 1						       HTTP_BUILD_QUERY(3)

http_build_query - Generate URL-encoded query string

SYNOPSIS
string http_build_query PHP_QUERY_RFC1738 (mixed $query_data, [string $numeric_prefix], [string $arg_separator], [int $enc_type]) DESCRIPTION
Generates a URL-encoded query string from the associative (or indexed) array provided. PARAMETERS
o $query_data - May be an array or object containing properties. If $query_data is an array, it may be a simple one-dimensional structure, or an array of arrays (which in turn may contain other arrays). If $query_data is an object, then only public properties will be incorporated into the result. o $numeric_prefix - If numeric indices are used in the base array and this parameter is provided, it will be prepended to the numeric index for ele- ments in the base array only. This is meant to allow for legal variable names when the data is decoded by PHP or another CGI application later on. o $arg_separator -arg_separator.output is used to separate arguments, unless this parameter is specified, and is then used. o $enc_type - By default, PHP_QUERY_RFC1738. If $enc_type is PHP_QUERY_RFC1738, then encoding is performed per RFC 1738 and the applica- tion/x-www-form-urlencoded media type, which implies that spaces are encoded as plus ( +) signs. If $enc_type is PHP_QUERY_RFC3986, then encoding is performed according to RFC 3986, and spaces will be percent encoded ( %20). RETURN VALUES
Returns a URL-encoded string. CHANGELOG
+--------+------------------------------------------+ |Version | | | | | | | Description | | | | +--------+------------------------------------------+ | 5.4.0 | | | | | | | The $enc_type parameter was added. | | | | | 5.1.3 | | | | | | | Square brackets are escaped. | | | | | 5.1.2 | | | | | | | The $arg_separator parameter was added. | | | | +--------+------------------------------------------+ EXAMPLES
Example #1 Simple usage of http_build_query(3) <?php $data = array('foo'=>'bar', 'baz'=>'boom', 'cow'=>'milk', 'php'=>'hypertext processor'); echo http_build_query($data) . " "; echo http_build_query($data, '', '&amp;'); ?> The above example will output: foo=bar&baz=boom&cow=milk&php=hypertext+processor foo=bar&amp;baz=boom&amp;cow=milk&amp;php=hypertext+processor Example #2 http_build_query(3) with numerically index elements. <?php $data = array('foo', 'bar', 'baz', 'boom', 'cow' => 'milk', 'php' =>'hypertext processor'); echo http_build_query($data) . " "; echo http_build_query($data, 'myvar_'); ?> The above example will output: 0=foo&1=bar&2=baz&3=boom&cow=milk&php=hypertext+processor myvar_0=foo&myvar_1=bar&myvar_2=baz&myvar_3=boom&cow=milk&php=hypertext+processor Example #3 http_build_query(3) with complex arrays <?php $data = array('user'=>array('name'=>'Bob Smith', 'age'=>47, 'sex'=>'M', 'dob'=>'5/12/1956'), 'pastimes'=>array('golf', 'opera', 'poker', 'rap'), 'children'=>array('bobby'=>array('age'=>12, 'sex'=>'M'), 'sally'=>array('age'=>8, 'sex'=>'F')), 'CEO'); echo http_build_query($data, 'flags_'); ?> this will output : (word wrapped for readability) user%5Bname%5D=Bob+Smith&user%5Bage%5D=47&user%5Bsex%5D=M& user%5Bdob%5D=5%2F12%2F1956&pastimes%5B0%5D=golf&pastimes%5B1%5D=opera& pastimes%5B2%5D=poker&pastimes%5B3%5D=rap&children%5Bbobby%5D%5Bage%5D=12& children%5Bbobby%5D%5Bsex%5D=M&children%5Bsally%5D%5Bage%5D=8& children%5Bsally%5D%5Bsex%5D=F&flags_0=CEO Note Only the numerically indexed element in the base array "CEO" received a prefix. The other numeric indices, found under pas- times, do not require a string prefix to be legal variable names. Example #4 Using http_build_query(3) with an object <?php class parentClass { public $pub = 'publicParent'; protected $prot = 'protectedParent'; private $priv = 'privateParent'; public $pub_bar = Null; protected $prot_bar = Null; private $priv_bar = Null; public function __construct(){ $this->pub_bar = new childClass(); $this->prot_bar = new childClass(); $this->priv_bar = new childClass(); } } class childClass { public $pub = 'publicChild'; protected $prot = 'protectedChild'; private $priv = 'privateChild'; } $parent = new parentClass(); echo http_build_query($parent); ?> The above example will output: pub=publicParent&pub_bar%5Bpub%5D=publicChild SEE ALSO
parse_str(3), parse_url(3), urlencode(3), array_walk(3). PHP Documentation Group HTTP_BUILD_QUERY(3)
All times are GMT -4. The time now is 12:23 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy