bernattorras / dompdf

Automatically exported from code.google.com/p/dompdf
0 stars 0 forks source link

Include version number in a DOMPDF_VERSION define #487

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
I'd like to be able to discover the version of dompdf without having to resort 
to the following:

  // Poor man's way to find dompdf version
  if (!defined('DOMPDF_DIR')) {
    return 'unknown';
  }
  else if (!defined('DOMPDF_CHROOT')) {
    return '0.5.1';
  }
  elseif (!defined('DOMPDF_FONT_CACHE')) {
    return '0.5.2';
  }
  elseif (!defined('DOMPDF_LOG_OUTPUT_FILE')) {
    return '0.6.0 beta1';
  }
  elseif (!defined('DOMPDF_ADMIN_USERNAME')) {
    return '0.6.0 beta2';
  }
  else {
    return '0.6.0 beta3';
  }

Ideally, create a define (e.g. DOMPDF_VERSION) with the version number of each 
release.

Thanks

Joao Ventura
(maintainer of the Drupal print module, which integrates with dompdf)

Original issue reported on code.google.com by j...@venturas.org on 21 May 2012 at 8:46

GoogleCodeExporter commented 8 years ago

Original comment by eclecticgeek on 24 May 2013 at 3:00