$thumb_path = $this->cfg->base_path ."/thumbs/". $this->cfg->photo_width ."_". $this->getMD5($photo);
if(!file_exists($orig_path)) {
- print "Photo ". $orig_path ." does not exist!<br />\n";
+ $this->_warning("Photo ". $orig_path ." does not exist!<br />\n");
}
if(!is_readable($orig_path)) {
- print "Photo ". $orig_path ." is not readable for user ". get_current_user() ."<br />\n";
+ $this->_warning("Photo ". $orig_path ." is not readable for user ". get_current_user() ."<br />\n");
}
/* If the thumbnail doesn't exist yet, try to create it */
$this->tmpl->assign('tags', $this->get_photo_tags($photo));
}
else {
- print "Can't open file ". $thumb_path ."\n";
+ $this->_warning("Can't open file ". $thumb_path ."\n");
}
if($previous_img) {
$filesize = rand($filesize/1024, 2);
if(!file_exists($orig_path)) {
- print "Photo ". $orig_path ." does not exist!<br />\n";
+ $this->_warning("Photo ". $orig_path ." does not exist!<br />\n");
return;
}
if(!is_readable($orig_path)) {
- print "Photo ". $orig_path ." is not readable for user ". get_current_user() ."<br />\n";
+ $this->_warning("Photo ". $orig_path ." is not readable for user ". get_current_user() ."<br />\n");
return;
}
$full_path = $this->translate_path($details['directory_path']) ."/". $details['name'];
if(!file_exists($full_path)) {
- print "File ". $full_path ." does not exist\n";
+ $this->_warning("File ". $full_path ." does not exist\n");
return;
}
if(!is_readable($full_path)) {
- print "File ". $full_path ." is not readable for ". get_current_user() ."\n";
+ $this->_warning("File ". $full_path ." is not readable for ". get_current_user() ."\n");
return;
}
} // checkifImageSupported()
+ public function _warning($text)
+ {
+ print "<img src=\"resources/green_info.png\" alt=\"warning\" />\n";
+ print $text;
+
+ } // _warning()
+
}
?>