PhpRiot
Become Zend Certified

Prepare for the ZCE exam using our quizzes (web or iPad/iPhone). More info...


When you're ready get 7.5% off your exam voucher using voucher CJQNOV23 at the Zend Store

Equality

Zend_Locale also provides a convenience function to compare two locales. All locale-aware classes should provide a similar equality check.

Example 550. Check for equal locales

<?php
$locale 
= new Zend_Locale();
$mylocale = new Zend_Locale('en_US');

// Check if locales are equal
if ($locale->equals($mylocale)) {
    print 
"Locales are equal";
}

Zend Framework