Skip to content

Latest commit

 

History

History
executable file
·
35 lines (20 loc) · 598 Bytes

README.md

File metadata and controls

executable file
·
35 lines (20 loc) · 598 Bytes

linkedinURLValidator

linkedinURLValidator class is used to validate the linkedin public url.

##How to use


require_once 'linkedinURLValidator.php';

$url = 'http://www.linkedin.com/company/xxxxxxx';

$validator = new linkedinURLValidator($url);

$result = $validator->validate();


if($result['valid'] && $result['type'] == 'company'){
	
	echo 'Url is valid linkedin company url ';
	echo $validator->get_company_id();
}
else if($result['valid']){

    echo 'Url is valid linkedin public profile url';
}
else{
    echo 'Url is not linkedin public profile url';
}