BUGFIX Fixed undefined calls to URL() in SimpleImageField, replacing them with getURL() instead (from r94301)

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@95594 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
Sean Harvey 2009-12-16 05:37:58 +00:00
parent bf9358ee46
commit f7dfa4d2bc

View File

@ -36,9 +36,9 @@ class SimpleImageField extends FileField {
if($imageField && $imageField->exists()) {
$html .= '<div class="thumbnail">';
if($imageField->hasMethod('Thumbnail') && $imageField->Thumbnail()) {
$html .= "<img src=\"".$imageField->Thumbnail()->URL()."\" />";
$html .= "<img src=\"".$imageField->Thumbnail()->getURL()."\" />";
} else if($imageField->CMSThumbnail()) {
$html .= "<img src=\"".$imageField->CMSThumbnail()->URL()."\" />";
$html .= "<img src=\"".$imageField->CMSThumbnail()->getURL()."\" />";
}
$html .= '</div>';
}