You are here

public static function PHPExcel_Shared_String::StrToTitle in Loft Data Grids 6.2

Same name and namespace in other branches
  1. 7.2 vendor/phpoffice/phpexcel/Classes/PHPExcel/Shared/String.php \PHPExcel_Shared_String::StrToTitle()

* Convert a UTF-8 encoded string to title/proper case * (uppercase every first character in each word, lower case all other characters) * *

Parameters

string $pValue UTF-8 encoded string: * @return string

1 call to PHPExcel_Shared_String::StrToTitle()
PHPExcel_Calculation_TextData::PROPERCASE in vendor/phpoffice/phpexcel/Classes/PHPExcel/Calculation/TextData.php
* PROPERCASE * * Converts a string value to upper case. * *

File

vendor/phpoffice/phpexcel/Classes/PHPExcel/Shared/String.php, line 621

Class

PHPExcel_Shared_String
PHPExcel_Shared_String

Code

public static function StrToTitle($pValue = '') {
  if (function_exists('mb_convert_case')) {
    return mb_convert_case($pValue, MB_CASE_TITLE, "UTF-8");
  }
  return ucwords($pValue);
}