我需要改变这个话题,我不能发表新主题.我已更新脚本,并安装新包.我仍然得到错误,但不是我最后发布的那个.
_ _ _
__ _ _ __ __ _ _ _ | | __ _ _ __ ___ | |(_)
/ _` || '_ \ / _` || | | || | / _` || '__|_____ / __|| || |
| (_| || | | || (_| || |_| || || (_| || | |_____|| (__ | || |
\__,_||_| |_| \__, | \__,_||_| \__,_||_| \___||_||_|
|___/
angular-cli: 1.0.0-beta.26
node: 8.12.0
os: linux x64
@angular/animations: 6.1.9
@angular/cdk: 6.4.7
@angular/common: …
Run Code Online (Sandbox Code Playgroud) 我有一个出租车系统,这个代码给了我
<?php
namespace App\Controllers;
use Illuminate\Http\Request;
class Controller
{
public Request $request;
public array $user;
public function __construct()
{
$this->user = [];
$this->request = Request::capture();
if (key_exists('user', $_SESSION)) {
$this->user = $_SESSION['user'];
}
if (count($this->user) === 0 && url()->contains('panel')) {
return redirect(url('login-form'));
}
}
}
Run Code Online (Sandbox Code Playgroud)
但是在编写这些代码行后系统给了我错误
ParseError
syntax error, unexpected 'Request' (T_STRING), expecting function (T_FUNCTION) or const (T_CONST)
Run Code Online (Sandbox Code Playgroud) 我试图弄清楚这个验证我的 Android 电话号码的工作原理。
我已添加代码并希望验证 46123456789,但最后一个数字 (9) 并未添加到电话号码中。
我用这个:
/**
* @param phone
* @return The number which satisfies the above criteria, is a valid mobile Number.
* The first digit should contain number between 0 to 9.
* The rest 9 digit can contain any number between 0 to 9.
* The mobile number can have 11 digits also by including 0 at the starting.
* The mobile number can be of 12 digits also by including 46 at the …
Run Code Online (Sandbox Code Playgroud)