From 89799cb83a6ed7bec9f50565061ee3d76d4d34b0 Mon Sep 17 00:00:00 2001 From: Alfred Bez Date: Tue, 22 Jul 2014 08:05:00 +0200 Subject: [PATCH] initial commit --- README.md | 8 ++++++++ metadata.php | 28 ++++++++++++++++++++++++++++ models/ab_htmlmin.php | 22 ++++++++++++++++++++++ 3 files changed, 58 insertions(+) create mode 100644 README.md create mode 100644 metadata.php create mode 100644 models/ab_htmlmin.php diff --git a/README.md b/README.md new file mode 100644 index 0000000..3d0fc36 --- /dev/null +++ b/README.md @@ -0,0 +1,8 @@ +HTML minify +============================= +Enables Smarty 'trimwhitespace' Outputfilter to minify HTML Code + +Installation +------------ + +1. Activate module in the OXID backend \ No newline at end of file diff --git a/metadata.php b/metadata.php new file mode 100644 index 0000000..9636e27 --- /dev/null +++ b/metadata.php @@ -0,0 +1,28 @@ + + * Author URI: http://www.alfredbez.de + */ + +/** + * Metadata version + */ +$sMetadataVersion = '1.1'; + +/** + * Module information + */ +$aModule = array( + 'id' => 'ab_htmlmin', + 'title' => 'Alfred Bez :: HTML minify', + 'description' => 'entfernt unnötige Whitespaces aus dem HTML-Code', + 'version' => '1.0', + 'author' => 'Alfred Bez', + 'url' => 'http://www.alfredbez.de', + 'email' => 'alfred.bez@gmail.com', + 'extend' => array( + 'oxutilsview' => 'ab_htmlmin/models/ab_htmlmin' + ) +); diff --git a/models/ab_htmlmin.php b/models/ab_htmlmin.php new file mode 100644 index 0000000..9883820 --- /dev/null +++ b/models/ab_htmlmin.php @@ -0,0 +1,22 @@ + + */ +class ab_htmlmin extends ab_htmlmin_parent { + + protected function _fillCommonSmartyProperties( $oSmarty ) + { + parent::_fillCommonSmartyProperties($oSmarty); + include_once dirname(__FILE__).'/smarty/plugins/outputfilter.trimwhitespace.php'; + $oSmarty->load_filter ('output' , 'trimwhitespace'); + } +} \ No newline at end of file