limingxinleo/x-phalcon-request

Phalcon Request Library

1.0.2 2018-02-06 09:10 UTC

This package is auto-updated.

Last update: 2021-04-17 11:16:34 UTC


README

Phalcon Request Library

获取依赖注入服务

<?php
use Phalcon\Di\FactoryDefault;
use Xin\Phalcon\Http\Request;

$di = new FactoryDefault();
$di->setShared('request', function () {
    return new Request();
});

获取上传的文件

<?php
use Phalcon\Di;
$di = Di::getDefault();
$file = $di->getShared('request')->getFile('file');