//set address block defaults
CRM_Contact_Form_Edit_Address::setDefaultValues( $defaults, $this );
+
if (!empty($defaults['image_URL'])) {
- list($imageWidth, $imageHeight) = getimagesize($defaults['image_URL']);
+ list($imageWidth, $imageHeight) = getimagesize(CRM_Utils_String::unstupifyUrl($defaults['image_URL']));
list($imageThumbWidth, $imageThumbHeight) = CRM_Contact_BAO_Contact::getThumbSize($imageWidth, $imageHeight);
$this->assign('imageWidth', $imageWidth);
$this->assign('imageHeight', $imageHeight);
}
}
+ /**
+ * Use the form name to create the tpl file name
+ *
+ * @return string
+ * @access public
+ */
+ /**
+ * @return string
+ */
function getTemplateFileName() {
if ($this->_contactSubType) {
$templateFile = "CRM/Contact/Form/Edit/SubType/{$this->_contactSubType}.tpl";