diff options
author | flop25 <flop25@piwigo.org> | 2012-07-08 17:16:41 +0000 |
---|---|---|
committer | flop25 <flop25@piwigo.org> | 2012-07-08 17:16:41 +0000 |
commit | 618c983b9d9b265be214943c146364bae56307b9 (patch) | |
tree | 0cb50f31527a821cf6f854508ae4ebf18c68dc5e /include/derivative.inc.php | |
parent | 911ce29f9436c559dbdffe41c0a3944993f9e6f6 (diff) |
merge r16507 from branch 2.4 to trunk
bug:2683
create get_size_css
git-svn-id: http://piwigo.org/svn/trunk@16508 68402e56-0260-453c-a942-63ccdbb3a9ee
Diffstat (limited to 'include/derivative.inc.php')
-rw-r--r-- | include/derivative.inc.php | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/include/derivative.inc.php b/include/derivative.inc.php index a3b944e72..d19b5a1b8 100644 --- a/include/derivative.inc.php +++ b/include/derivative.inc.php @@ -314,6 +314,15 @@ final class DerivativeImage return $this->params->compute_final_size($this->src_image->get_size()); } + function get_size_css() + { + $size = $this->get_size(); + if ($size) + { + return 'width:'.$size[0].'px; height:'.$size[1].'px'; + } + } + function get_size_htm() { $size = $this->get_size(); |