2017 © Pedro Peláez
 

package laravel-punycode

Package for encoding of Unicode for Internationalized Domain Names in Applications (IDNA)

image

fomvasss/laravel-punycode

Package for encoding of Unicode for Internationalized Domain Names in Applications (IDNA)

  • Wednesday, June 13, 2018
  • by fomvasss
  • Repository
  • 1 Watchers
  • 0 Stars
  • 149 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 3 Versions
  • 231 % Grown

The README.md

Laravel Punycode

This package converts a Unicode encoded domain name to a IDNA ASCII form and vice-versa., (*1)

Install

Run:, (*2)

composer require "fomvasss/laravel-punycode"

For Laravel < 5.5 Add in ServiceProvider to the providers array in config/app.php, (*3)

  Fomvasss\Punycode\PunycodeServiceProvider::class,

Publish configs (optional):, (*4)

php artisan vendor:publish --provider="Fomvasss\Punycode\PunycodeServiceProvider" --tag="config"

Usage

Usage facade

You can now using the facade, using the PSR-3 levels (encode, decode): Add in your class the facade:, (*5)

use Fomvasss\Punycode\Facades\Punycode;

Example usage:, (*6)

var_dump(Punycode::encode('веб-вест.сайт'));
// outputs: xn----9sbccmd8fi.xn--80aswg;

var_dump(Punycode::decode('xn----9sbccmd8fi.xn--80aswg'));
// outputs: веб-вест.сайт

Usage helper functions

punycode_encode('веб-вест.сайт');
punycode_decode('xn----9sbccmd8fi.xn--80aswg');

Links:

  • https://github.com/true/php-punycode

License

Faker is released under the MIT Licence. See the bundled LICENSE file for details., (*7)

The Versions

13/06 2018

dev-master

9999999-dev

Package for encoding of Unicode for Internationalized Domain Names in Applications (IDNA)

  Sources   Download

MIT

The Requires

 

by Fomin Vasyl

laravel domain idn punycode

13/06 2018

1.1.0

1.1.0.0

Package for encoding of Unicode for Internationalized Domain Names in Applications (IDNA)

  Sources   Download

MIT

The Requires

 

by Fomin Vasyl

laravel domain idn punycode

15/06 2017

v1.0.0

1.0.0.0

Package for encoding of Unicode for Internationalized Domain Names in Applications (IDNA)

  Sources   Download

MIT

The Requires

 

by Fomin Vasyl

laravel domain idn punycode