balazscsaba2006 / socially
Library to validate and parse social media profile URLs
Installs: 36 889
Dependents: 0
Suggesters: 0
Security: 0
Stars: 2
Watchers: 2
Forks: 0
Open Issues: 0
Requires
- php: ^7.4 || ^8.0
- ext-json: *
- ext-mbstring: *
- utopia-php/domains: ^0.3
Requires (Dev)
- phpunit/phpunit: ^9.5
README
Socially
Library to validate and parse social media profile URLs.
Currently supported social media platforms:
- Github
- Google Plus
- AngelList
- Gravatar
- Klout
- Behance
- Bitbucket
- Dribbble
- Flickr
- Stackoverflow
- Quora
Requirements
- PHP: >= 7.1
- PHP extensions:
- mbstring
- json
- layershifter/tld-extract: ^2.0
Installation
The recommended way is using Composer. You also can download the latest release and start from there.
Composer
If you don’t have Composer installed, follow the installation instructions.
Once composer is installed, execute the following command in your project root to install this library:
composer require balazscsaba2006/socially
Finally, remember to include the autoloader to your project:
require __DIR__ . '/vendor/autoload.php';
Usage
$parser = = new Parser(); $result = $parser->isSocialMediaProfile($url);
For more examples on usage take a look at the /tests
directory.
Contributing
I’d be happy if you contribute to this library. Please try to follow the existing coding style and use proper comments in your commit message. Thanks! 🙇
License
Please see the license file for more information.