Skip to content

mozhou-tech/ucenter-client

 
 

Repository files navigation

UcenterClient

Introduction

UcenterClient is a ucenter client for zf2.

[ucenter]http://www.comsenz.com/products/ucenter

Installation

download this project it into ./vendor/ or ./modules/

Post installation

  1. Enabling it in your application.config.phpfile.

    <?php
    return array(
        'modules' => array(
            'UcenterClient',
        ),
        // ...
    );
  2. Copy the config/ucenter.global.php.dist file into your ./config/autoload directory. (Remove the .distpart) and configure it

  3. use

    // ...
    $cookie = $this->getRequest()->getCookie();
    if ($cookie->offsetExists('ucenter_auth')) {
       $param = $cookie->offsetGet('ucenter_auth');
       $uc = $this->getServiceLocator()->get('ucenter_service');
       $user = $uc->getUser($param);
    }
    // ...
  4. Any problem email to runphp@qq.com

About

zf2 ucenter client

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • PHP 100.0%