Currently, in my /etc/system.xml file, I can use this to pull out a complete list of regions that are stored in Magento and display them as a multi-segment. This works great, but I would only prefer to push regions for one country, for example. counties of Great Britain or states of the USA:
<counties translate="label">
<label>Counties</label>
<frontend_type>multiselect</frontend_type>
<sort_order>10</sort_order>
<source_model>adminhtml/system_config_source_allregion</source_model>
<show_in_default>1</show_in_default>
<show_in_website>1</show_in_website>
<show_in_store>1</show_in_store>
</counties>
The reason for this is that I added a lot of regions / states / districts to the system, and now it is not a very user-friendly selection field.
UPDATE:
After you did not immediately answer the solutions below, I again considered this problem after a while to assemble my own solution based on the answers received.
// /Mage/Adminhtml/Model/System/Config/Source/Allregion.php app/code/core/Mage/Adminhtml/Model/System/Config/Source/Ukregion.php
Mage_Adminhtml_Model_System_Config_Source_Ukregion.
:
$regionsCollection = Mage::getResourceModel('directory/region_collection')->load();
:
$regionsCollection = Mage::getResourceModel('directory/region_collection')->addCountryFilter('GB')->load();
( , " " ).
, system.xml:
<counties translate="label">
<label>Counties</label>
<frontend_type>multiselect</frontend_type>
<sort_order>10</sort_order>
<source_model>adminhtml/system_config_source_ukregion</source_model>
<show_in_default>1</show_in_default>
<show_in_website>1</show_in_website>
<show_in_store>1</show_in_store>
</counties>
"" "GB" - GB NI, " ". "" , .