GithubHelp home page GithubHelp logo

seandz / identicon-avatar Goto Github PK

View Code? Open in Web Editor NEW

This project forked from valiner/identicon-avatar

0.0 1.0 0.0 8 KB

📷生成identicon头像,头像图片生成 http://iden.jay-zhou.cn

PHP 100.00%

identicon-avatar's Introduction

identicon-avatar

Build Status

identicon 根据一个字符串(可以是用户的ID或者IP)的哈希值生成大量不重复的头像 很多大型IT网站上可以见到,比如 Github、Sourceforge、Stackoveflow。

安装

$ composer require valiner/identicon-avatar -vvv

使用

非laravel

<?php
require __DIR__.'/vendor/autoload.php';

use Valiner\IdenticonAvatar\Identicon;

$identicon = new Identicon();
//浏览器输出'sdp'的125px的图像
$identicon->getAvatar('sdp',125);

laravel

app('identicon')->getAvatar('sdp',125);

方法

浏览器输出'sdp'的125px的图像

$identicon->getAvatar('sdp',125)

保存'sdp'的125px的图像的图像到本地

$identicon->saveAvatar('sdp',125,__DIR_.'/test.png')

获取'sdp'的125px的图像的的BASE64

$identicon->getAvatarDataUri('sdp',125)

License

MIT

identicon-avatar's People

Contributors

cargravity avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.