trigger_error("sugarvar: missing 'key' parameter"); return; } $object = (empty($params['objectName']))?$smarty->get_template_vars('parentFieldArray'): $params['objectName']; $vardefs = $smarty->get_template_vars('vardef'); $member = $vardefs['name']; $_contents = '$'. $object . '.' . $member . '.' . $params['key']; return $_contents; }