<?php
/*
+--------------------------------------------------------------------+
- | CiviCRM version 4.4 |
+ | CiviCRM version 4.5 |
+--------------------------------------------------------------------+
- | Copyright CiviCRM LLC (c) 2004-2013 |
+ | Copyright CiviCRM LLC (c) 2004-2014 |
+--------------------------------------------------------------------+
| This file is a part of CiviCRM. |
| |
/**
*
* @package CRM
- * @copyright CiviCRM LLC (c) 2004-2013
+ * @copyright CiviCRM LLC (c) 2004-2014
* $Id$
*
*/
//get the tokens for Mailing Label field
$tokens = CRM_Core_SelectValues::contactTokens();
- natcasesort($tokens);
- $this->assign('tokens', json_encode($tokens));
-
- $this->add('select', 'token1', ts('Insert Token'),
- $tokens, FALSE,
- array(
- 'size' => "5",
- 'multiple' => TRUE,
- 'onclick' => "return tokenReplText(this);",
- )
- );
+ $this->assign('tokens', CRM_Utils_Token::formatTokensForDisplay($tokens));
parent::buildQuickForm();
}
";
$countyCount = CRM_Core_DAO::singleValueQuery($sql);
if ($countyCount < 10) {
- global $civicrm_root;
- $sqlFilePath = $civicrm_root . DIRECTORY_SEPARATOR . 'sql' . DIRECTORY_SEPARATOR . 'counties.US.sql.gz';
-
- CRM_Core_Session::setStatus("", ts('You have enabled the County option. Please ensure you populate the county table in your CiviCRM Database. You can find a list of US counties (in gzip format) in your distribution at: <em>%1</em>',
- array(1 => $sqlFilePath)),
+ CRM_Core_Session::setStatus(ts('You have enabled the County option. Please ensure you populate the county table in your CiviCRM Database. You can find extensions to populate counties in the ') . CRM_Utils_System::href(ts('CiviCRM Extensions Directory'), 'civicrm/admin/extensions', array('reset' => 1), TRUE, 'extensions-addnew'),
+ ts('Populate counties'),
"info"
);
}