本文整理汇总了PHP中str::title方法的典型用法代码示例。如果您正苦于以下问题:PHP str::title方法的具体用法?PHP str::title怎么用?PHP str::title使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类str
的用法示例。
在下文中一共展示了str::title方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: checkErf
/**
* Show the form for creating a new resource.
*
* @return \Illuminate\Http\Response
*/
public function checkErf($street)
{
// dynamically change database
$userDB = Auth::user()->suburb;
$otf = new \App\Database\OTF(['database' => $userDB]);
$db = DB::connection($userDB);
// check database type
$databaseType = Auth::user()->suburb_type;
if ($databaseType == 1) {
$freeholds_table = "tblSuburbOwners";
$freeholds_table_key = $freeholds_table . ".numErf";
$freeholds_identity = $freeholds_table . ".strIdentity";
$mem_Table = "tblErfNumbers";
$mem_key = "tblErfNumbers.numErf";
}
if ($databaseType == 2) {
$freeholds_table = "tblSuburbOwners";
$freeholds_table_key = $freeholds_table . ".strKey";
$freeholds_identity = $freeholds_table . ".strIdentity";
$mem_Table = "tblFHPropertyID";
$mem_key = $mem_Table . ".strKey";
}
if ($databaseType == 3) {
$freeholds_table = "tblSuburbOwners";
$freeholds_table_key = $freeholds_table . ".strKey";
$freeholds_identity = $freeholds_table . ".strIdentity";
$mem_Table = "tblFHPropertyID";
$mem_key = $mem_Table . ".strKey";
}
$streets = $db->table($freeholds_table)->Join($mem_Table, $freeholds_table_key, '=', $mem_key)->Join('tblSuburbContactNumbers', $freeholds_identity, '=', 'tblSuburbContactNumbers.strIDNumber')->orderBy('strStreetName', 'asc')->orderBy('strStreetNo', 'asc')->orderBy($freeholds_table . '.strComplexName', 'asc')->orderBy($freeholds_table . '.strComplexNo', 'asc')->orderBy($freeholds_table . '.strKey', 'asc')->select('*')->groupby($freeholds_table . '.ID')->where($freeholds_table . '.numErf', $street)->paginate(1);
// format phone and currency
foreach ($streets as $value) {
$value->strHomePhoneNo = helpers::phoneFormat($value->strHomePhoneNo);
$value->strWorkPhoneNo = helpers::phoneFormat($value->strWorkPhoneNo);
$value->strCellPhoneNo = helpers::phoneFormat($value->strCellPhoneNo);
$value->strAmount = helpers::currencyFormat($value->strAmount);
$value->strBondAmount = helpers::currencyFormat($value->strBondAmount);
$value->strSurname = str::title($value->strSurname);
$value->strFirstName = str::title($value->strFirstName);
}
// log
$radio = 'checkErf';
$append = Auth::user()->name . " " . \Carbon\Carbon::now()->toDateTimeString() . " " . 'streetscontroller ' . $radio . " " . $street . " " . $userDB;
Storage::append('logfile.txt', $append);
return view('pages.streets1', compact('streets', 'street'));
dd('checkgrid streetcontroller', $street);
}