jonnybarnes / indieweb
IndieWeb helper functions
Installs: 7 546
Dependents: 0
Suggesters: 0
Security: 0
Stars: 1
Watchers: 3
Forks: 0
Open Issues: 0
Requires
- php: ^7.3|^8.0
- ext-intl: *
- ext-mbstring: *
Requires (Dev)
- phpunit/phpunit: ^9.0
README
#IndieWeb helpers These tools should help with things like POSSE-ing. Currently I'm only working with Twitter but adding other services is in the pipeline.
##Installing Super simple with composer:
composer require jonnybarnes/indieweb
##Numbers
The Numbers
class allows you to convert between decimal and either NewBase60
or NewBase64, and vice versa.
$numbers = new Numbers(); $nb60id = $numbers->b60tunum($realId);
##NotePrep
The NotePrep
class is for use when preparing a note that you want to
POSSE to another site, such as Twitter. With a
provided note the createNote
method will add a link to the original copy,
truncating the note if necessary.
$noteprep = new NotePrep(); $originalNote = 'A lovely note.'; $posseCopy = $noteprep->createNote($note, 'https://abc.de/n/id', 140, true); echo $posseCopy;// 'A lovely note. (https://abc.de/n/id)'
##License As a library intended for use in the IndieWeb this is Licensed under the Creative Commons Zero license.