projects
/
civicrm-core.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
copyright and version fixes
[civicrm-core.git]
/
CRM
/
Utils
/
Geocode
/
Google.php
diff --git
a/CRM/Utils/Geocode/Google.php
b/CRM/Utils/Geocode/Google.php
index aba9acc525102f5a659fec8d20a89e8d7f77feaa..d9ceaed0124b5a6c1090533fbe7ac416490e881e 100644
(file)
--- a/
CRM/Utils/Geocode/Google.php
+++ b/
CRM/Utils/Geocode/Google.php
@@
-1,9
+1,9
@@
<?php
/*
+--------------------------------------------------------------------+
<?php
/*
+--------------------------------------------------------------------+
- | CiviCRM version 4.
4
|
+ | CiviCRM version 4.
5
|
+--------------------------------------------------------------------+
+--------------------------------------------------------------------+
- | Copyright CiviCRM LLC (c) 2004-201
3
|
+ | Copyright CiviCRM LLC (c) 2004-201
4
|
+--------------------------------------------------------------------+
| This file is a part of CiviCRM. |
| |
+--------------------------------------------------------------------+
| This file is a part of CiviCRM. |
| |
@@
-28,7
+28,7
@@
/**
*
* @package CRM
/**
*
* @package CRM
- * @copyright CiviCRM LLC (c) 2004-201
3
+ * @copyright CiviCRM LLC (c) 2004-201
4
* $Id$
*
*/
* $Id$
*
*/
@@
-66,7
+66,7
@@
class CRM_Utils_Geocode_Google {
*/
static function format(&$values, $stateName = FALSE) {
// we need a valid country, else we ignore
*/
static function format(&$values, $stateName = FALSE) {
// we need a valid country, else we ignore
- if (
!CRM_Utils_Array::value('country', $values
)) {
+ if (
empty($values['country']
)) {
return FALSE;
}
return FALSE;
}
@@
-74,7
+74,7
@@
class CRM_Utils_Geocode_Google {
$add = '';
$add = '';
- if (
CRM_Utils_Array::value('street_address', $values
)) {
+ if (
!empty($values['street_address']
)) {
$add = urlencode(str_replace('', '+', $values['street_address']));
$add .= ',+';
}
$add = urlencode(str_replace('', '+', $values['street_address']));
$add .= ',+';
}
@@
-85,8
+85,8
@@
class CRM_Utils_Geocode_Google {
$add .= ',+';
}
$add .= ',+';
}
- if (
CRM_Utils_Array::value('state_province', $values
)) {
- if (
CRM_Utils_Array::value('state_province_id', $values
)) {
+ if (
!empty($values['state_province']
)) {
+ if (
!empty($values['state_province_id']
)) {
$stateProvince = CRM_Core_DAO::getFieldValue('CRM_Core_DAO_StateProvince', $values['state_province_id']);
}
else {
$stateProvince = CRM_Core_DAO::getFieldValue('CRM_Core_DAO_StateProvince', $values['state_province_id']);
}
else {
@@
-109,12
+109,12
@@
class CRM_Utils_Geocode_Google {
}
}
}
}
- if (
CRM_Utils_Array::value('postal_code', $values
)) {
+ if (
!empty($values['postal_code']
)) {
$add .= '+' . urlencode(str_replace('', '+', $values['postal_code']));
$add .= ',+';
}
$add .= '+' . urlencode(str_replace('', '+', $values['postal_code']));
$add .= ',+';
}
- if (
CRM_Utils_Array::value('country', $values
)) {
+ if (
!empty($values['country']
)) {
$add .= '+' . urlencode(str_replace('', '+', $values['country']));
}
$add .= '+' . urlencode(str_replace('', '+', $values['country']));
}