public static function Braintree_Util::delimiterToUnderscore in Commerce Braintree 7
convert alpha-beta-gamma to alpha_beta_gamma
@access public
Parameters
string $string:
Return value
string modified string
2 calls to Braintree_Util::delimiterToUnderscore()
- Braintree_UtilTest::testDelimeterToUnderscore in braintree_php/
tests/ unit/ UtilTest.php - Braintree_Xml_Parser::_iteratorToArray in braintree_php/
lib/ Braintree/ Xml/ Parser.php - processes SimpleXMLIterator objects recursively
File
- braintree_php/
lib/ Braintree/ Util.php, line 129
Class
- Braintree_Util
- Braintree Utility methods
Code
public static function delimiterToUnderscore($string) {
return preg_replace('/-/', '_', $string);
}