Lasso Soft Inc. > Home

[lp_client_params]

Linklp_client_params
AuthorBil Corry
CategoryClient
Version8.x
LicensePublic Domain
Posted23 Dec 2005
Updated31 Mar 2008
More by this author...

Description

Returns an array of GET/POST parameters passed from the client.

Sample Usage

lp_client_params;

Source Code

Click the "Download" button below to retrieve a copy of this tag, including the complete documentation and sample usage shown on this page. Place the downloaded ".inc" file in your LassoStartup folder, restart Lasso, and you can begin using this tag immediately.

[

define_tag:'lp_client_params',
	-description='Returns an array of GET/POST parameters passed from the client.',
	-priority='replace',
	-optional='method';
	
	local:'out' = array;

	if: (local:'method') == 'GET';
		#out->(merge: client_getparams);
	else: (local:'method' == 'POST');
		#out->(merge: client_postparams);
	else; // both
		#out->(merge: client_getparams);
		#out->(merge: client_postparams);
	/if;	

	// correct charset issue in LP8.5.5
	if: client_encoding != content_encoding;
		local('i'=null,'name'=null,'value'=null);
		iterate: #out, #i;
			if: #i->type == 'pair';
				#name = (bytes:#i->name,client_encoding);
				#value = (bytes:#i->value,client_encoding);
				#i = (pair: #name->(exportstring:content_encoding) = #value->(exportstring:content_encoding));
			else;
				#name = (bytes:#i,client_encoding);
				#i = #name->(exportstring:content_encoding);
			/if;
		/iterate;
	/if;

	return:#out;

/define_tag;

]

Related Tags

Comments

No comments

Please log in to comment

Subscribe to the LassoTalk mail list

LassoSoft Inc. > Home

 

 

©LassoSoft Inc 2015 | Web Development by Treefrog Inc | PrivacyLegal terms and Shipping | Contact LassoSoft