diff --git a/core/image.class.php b/core/image.class.php index bbe9d86b..1692eae2 100644 --- a/core/image.class.php +++ b/core/image.class.php @@ -94,22 +94,22 @@ class Image { public function get_image_link() { global $config; - return $this->parse_link_template($config->get_string('image_ilink', '$base/image/$id.$ext')); + return $this->parse_link_template($config->get_string('image_ilink')); } public function get_short_link() { global $config; - return $this->parse_link_template($config->get_string('image_slink', '')); + return $this->parse_link_template($config->get_string('image_slink')); } public function get_thumb_link() { global $config; - return $this->parse_link_template($config->get_string('image_tlink', '$base/thumb/$id.jpg')); + return $this->parse_link_template($config->get_string('image_tlink')); } public function get_tooltip() { global $config; - return $this->parse_link_template($config->get_string('image_tip', '$tags // $size // $filesize'), "html_escape"); + return $this->parse_link_template($config->get_string('image_tip'), "html_escape"); } public function get_image_filename() { diff --git a/ext/image/main.php b/ext/image/main.php index b871fee0..c7b278c3 100644 --- a/ext/image/main.php +++ b/ext/image/main.php @@ -12,6 +12,10 @@ class ImageIO extends Extension { $config->set_default_int('thumb_height', 192); $config->set_default_int('thumb_quality', 75); $config->set_default_int('thumb_mem_limit', '8MB'); + + $config->set_default_string('image_ilink', '$base/image/$id.$ext'); + $config->set_default_string('image_tlink', '$base/thumb/$id.jpg'); + $config->set_default_string('image_tip', '$tags // $size // $filesize'); } if(is_a($event, 'PageRequestEvent')) { @@ -41,9 +45,9 @@ class ImageIO extends Extension { if(is_a($event, 'SetupBuildingEvent')) { $sb = new SetupBlock("Image Options"); $sb->position = 30; - $sb->add_text_option("image_ilink", "Image link "); - $sb->add_text_option("image_tlink", "
Thumbnail link "); - $sb->add_text_option("image_tip", "
Image tooltip "); + $sb->add_text_option("image_ilink", "Image link: "); + $sb->add_text_option("image_tlink", "
Thumbnail link: "); + $sb->add_text_option("image_tip", "
Image tooltip: "); $event->panel->add_block($sb); $thumbers = array();