You are here

function _swftools_zlib in SWF Tools 6.2

Same name and namespace in other branches
  1. 6.3 includes/swftools.admin.status.inc \_swftools_zlib()

Check for presence of the zlib library

Return value

Markup string for inclusion in report

1 call to _swftools_zlib()
swftools_status in ./swftools.admin.status.inc
Generate a status report for SWF Tools methods / players / media defaults

File

./swftools.admin.status.inc, line 262

Code

function _swftools_zlib() {
  $has_zlib = extension_loaded('zlib');
  $requirements['swftools'] = array(
    'title' => t('Zlib library'),
    'description' => '',
    'value' => $has_zlib ? t('Enabled') : t('Not installed'),
    'severity' => $has_zlib ? REQUIREMENT_OK : REQUIREMENT_WARNING,
  );

  // Generate the output string and return it
  $html = t('<h3>Zlib library</h3>');
  $html .= t('<p>SWF Tools requires the <a href="@url">zlib library</a> in order to automatically determine the dimensions of compressed swf files. If this library is not installed then SWF Tools will work but you may have to specify the size of swf content when it is produced, otherwise the content may not appear in some browsers.</p>', array(
    '@url' => 'http://www.php.net/zlib',
  ));
  $html .= theme('status_report', $requirements);
  return $html;
}