$project_name = 'OCT16: Some Project';
$project_name = preg_replace("/\b[A-Z]{3,4}\d{2}:\s?/u", "", $project_name);
print_r($project_name); // "Some Project"
// another test case:
$project_name = ' Some Project OCT16: some text';
....
print_r($project_name); // "Some Project some text"
答案 0 :(得分:0)
你可以试试这个:
TelephonyManager telephonyManager =((TelephonyManager) Context.getSystemService(Context.TELEPHONY_SERVICE));
String operatorName = telephonyManager.getSimOperatorName();
您可以阅读更多here。 我希望能解决这个问题。祝你有愉快的一天!