99麻豆久久久国产免费福利精品,国产精品成人国产乱,玖玖操,手机看片169,国产精彩视频在线观看,午夜亚洲福利视频,国产伦乱视频

龍巖易富通網(wǎng)絡(luò)科技有限公司

龍巖小程序開發(fā),龍巖分銷系統(tǒng)

centos 定時(shí)執(zhí)行 think命令

2025.06.21 | 619閱讀 | 0條評(píng)論 | php

在TP5中自定義hello命令

<?php

    protected function configure()

    {

        $this->setName('hello')                      //定義命令的名字

        ->setDescription('This is my command')     //定義命令的描述

        ->addArgument('name')                      //增加一個(gè)名字參數(shù)

        ->addArgument('age');                      //增加一個(gè)年齡參數(shù)

    }


    protected function execute(Input $input, Output $output)

    {

        //獲取輸入的參數(shù)

        $name = $input->getArgument('name');

        $age = $input->getArgument('age');


        //輸出獲得的參數(shù)

        $output->writeln("My name is $name ,age is $age");

    }


centos定時(shí)執(zhí)行

* * * * *  php /path/to/your/project/think hello

贊 (

發(fā)表評(píng)論

鹤壁市| 闽清县| 双桥区| 公主岭市| 德安县| 合肥市| 兖州市| 永州市| 汶川县| 嘉峪关市| 固阳县| 五华县| 宜兰县| 青铜峡市| 永康市| 上高县| 吉首市| 民勤县| 宣汉县| 南昌县| 库尔勒市| 榆林市| 呼和浩特市| 张家界市| 铜川市| 平顺县| 南开区| 房山区| 广汉市| 泰兴市| 休宁县| 乌鲁木齐市| 永丰县| 海安县| 张家界市| 苍溪县| 仙桃市| 蓝山县| 元朗区| 高要市| 奈曼旗|