SeedDMS_Preview pear.php.net Create thumbnails from document content for SeedDMS SeedDMS is a web based document management system (DMS). These are the classes to create preview images and pdf file from the document content. Uwe Steinmann steinm uwe@steinmann.cx yes 2021-10-16 1.4.0 1.4.0 stable stable GPL License - use new conversion service if available - createRawPreview() checks early if a converter exists 4.3.0 1.5.4 2012-11-20 1.0.0 1.0.0 stable stable GPL License initial version 2013-04-29 1.1.0 1.1.0 stable stable GPL License preview image can also be created from a document file (SeedDMS_Core_DocumentFile) 2014-03-18 1.1.1 1.1.0 stable stable GPL License add converters for .tar.gz, .ps, .txt 2014-04-10 1.1.2 1.1.0 stable stable GPL License create fixed width image with proportional height 2015-02-13 1.1.3 1.1.0 stable stable GPL License preview images will also be recreated if the object this image belongs is of newer date than the image itself. This happens if versions are being deleted and than a new version is uploaded. Because the new version will get the version number of the old version, it will also take over the old preview image.Comparing the creation date of the image with the object detects this case. 2015-08-08 1.1.4 1.1.0 stable stable GPL License command for creating the preview will be called with a given timeout 2016-02-11 1.1.5 1.1.5 stable stable GPL License add method getFilesize() timeout for external commands can be passed to contructor of SeedDMS_Preview_Previewer 2016-03-08 1.1.6 1.1.6 stable stable GPL License check if object passed to createPreview(), hasPreview() is not null 2016-03-29 1.1.7 1.1.7 stable stable GPL License set last parameter of stream_select() to 200000 micro sec. in case the timeout in sec. is set to 0 2016-04-05 1.1.8 1.1.8 stable stable GPL License pass variables to stream_select (required by php7) 2016-04-26 1.1.9 1.1.9 stable stable GPL License add more documentation finish deletePreview() add new method deleteDocumentPreviews() fix calculation of timeout (Bug #269) check if cache dir exists before deleting it in deleteDocumentPreviews() 2016-11-07 1.2.0 1.2.0 stable stable GPL License add new previewer which converts document to pdf instead of png 2016-11-15 1.2.1 1.2.0 stable stable GPL License setConverters() overrides exiting converters 2017-03-02 1.2.2 1.2.0 stable stable GPL License commands can be set for mimetypes 'xxxx/*' and '*' pass mimetype as parameter '%m' to converter 2017-09-18 1.2.3 1.2.0 stable stable GPL License createPreview() returns false if running the converter command fails 2017-10-11 1.2.4 1.2.0 stable stable GPL License fix typo in converter for tar.gz files 2017-10-11 1.2.5 1.2.0 stable stable GPL License SeedDMS_Preview_Base::hasConverter() returns only try if command is set 2017-12-04 1.2.6 1.2.0 stable stable GPL License SeedDMS_Preview_Base::setConverters() overrides existing converters. New method SeedDMS_Preview_Base::addConverters() merges new converters with old ones. 2018-01-18 1.2.7 1.2.0 stable stable GPL License add SeedDMS_Preview_Base::sendFile() as a replacement for readfile() which uses mod_xsendfile if available execWithTimeout() reads data from stderr and returns it together with stdout in array 2018-03-08 1.2.8 1.2.0 stable stable GPL License preview is also created if SeedDMS_Core_DocumentContent has a child class 2018-07-13 1.2.9 1.2.9 stable stable GPL License make sure list of converters is always an array usage of mod_sendfile can be configured 2019-02-11 1.2.10 1.2.10 stable stable GPL License new parameter for enabling/disabling xsendfile fix creation of pdf preview if document content class is not SeedDMS_Core_DocumentContent 2020-02-17 1.3.0 1.3.0 stable stable GPL License add new methode getPreviewFile() 2020-03-21 1.3.1 1.3.1 stable stable GPL License add parameter $target to SeedDMS_Preview_pdfPreviewer::hasRawPreview() and SeedDMS_Preview_pdfPreviewer::getRawPreview() 2020-12-23 1.3.2 1.3.1 stable stable GPL License set header Content-Length update package description 2020-12-23 1.3.3 1.3.3 stable stable GPL License - close pipes in execWithTimeout(), also return exit code of command - createPreview() has optional parameter by referenz to return true if a preview image was actually created