Profile cover photo
Profile photo
Lars Moelleken
464 followers -
Webdeveloper && Sysadmin === DevOp
Webdeveloper && Sysadmin === DevOp

464 followers
About
Posts

Post has attachment
Portable UTF-8 library for PHP

Description:
The benefit of Portable UTF-8 is that it is easy to use, easy to bundle. This library will also auto-detect your server environment and will use the installed php-extensions if they are available, so you will have the best possible performance.

Install:
composer require voku/portable-utf8

Examples:

UTF8::cleanup('�Düsseldorf�'); // Düsseldorf

UTF8::binary_to_str('11110000100111111001100010000011'); // '😃'

UTF8::str_to_binary('😃'); // '11110000100111111001100010000011'

UTF8::htmlentities('<白-öäü>'); // '&lt;&#30333;-&ouml;&auml;&uuml;&gt;'

UTF8::html_entity_decode('&#20013;&#25991;&#31354;&#30333;'); // '中文空白'

UTF8::remove_bom("\xEF\xBB\xBFΜπορώ να"); // 'Μπορώ να'

...

Post has attachment

Post has attachment
Simple MySQLi Abstraction Layer + ActiveRecord

-> https://github.com/voku/simple-mysqli

Example:

```
$user = new User();
$user->name = 'demo';
$user->password = password_hash('demo', PASSWORD_BCRYPT, array("cost"=>15));
$user_id = $user->insert();

var_dump($user_id); // the new id
var_dump($user->id); // also the new id
var_dump($user->getPrimaryKey()); // also the new id
```

Post has shared content
Phonetic-Algorithms for fuzzy searching | #PHP -> https://packagist.org/packages/voku/phonetic-algorithms
Latest Classes: Phonetic Algorithms (New) - Package: Phonetic Algorithms Summary: Search text matching the sound of word Groups: Libraries, PHP

Post has shared content

Post has shared content
PHPUnit | use "assertSame()" instead of "assertEquals()" where possible #php
RT @Brunty: Remember: in PHPUnit use assertSame instead of assertEquals where possible: assertEquals(5, true); // pass assertSame(5, true); // fail

Post has attachment
# My array manipulation library for PHP, called Arrayy!

https://github.com/voku/Arrayy

This is an Multidimensional ArrayAccess Wrapper with support for dot-notation.

$arrayy = new A(['Lars' => ['lastname' => 'Moelleken']]);

$arrayy->get('Lars'); // ['lastname' => 'Moelleken']
$arrayy->get('Lars.lastname'); // 'Moelleken'

Post has attachment
If you are using Windows 10 and you need a real command line interface, then use "Ubuntu on Windows" ... | https://suckup.de/2017/04/ubuntu-windows-dotfiles/ #coding

Post has attachment
# URLify for PHP

A PHP port of URLify.js from the Django project + str_transliterate() from "Portable UTF-8".

https://github.com/voku/urlify

Example: echo URLify::filter('活动日起'); // 'Huo-Dong-Ri-Qi'

Post has attachment
# HtmlMin: HTML Compressor and Minifier via PHP 5.3+

HtmlMin is a fast and very easy to use PHP5.3+ library that minifies given HTML5 source by removing extra whitespaces, comments and other unneeded characters without breaking the content structure. As a result pages become smaller in size and load faster. It will also prepare the HTML for better gzip results, by re-ranging (sort alphabetical) attributes and css-class-names.

https://github.com/voku/HtmlMin

PS: there is also an twig-wrapper :-) | https://github.com/voku/html-compress-twig
Wait while more posts are being loaded