Lasso Soft Inc. > Home

[file_isanimatedgif]

Linkfile_isanimatedgif
AuthorJason Huck
CategoryFile
Version8.x
Licensehttp://opensource.org/licenses/artistic-license.php
Posted26 Oct 2005
Updated16 Jan 2006
More by this author...

Description

Returns true if the given file is an animated GIF.

Sample Usage

var('myFile' = '/path/to/file.gif');
file_isanimatedgif($myFile);

-> true

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(
	'isanimatedgif',
	-namespace='file_',
	-priority='replace',
	-description='Returns true if the specified file is an animated GIF.'
);
	protect;
		local('img') = image(params->first);
		#img->describe( -short) >> '.gif[0]' ? return(true) | return(false);
		
		handle_error;
			return(false);
		/handle_error;
	/protect;
/define_tag;

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