-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathlinkedin_profile_test.php
executable file
·36 lines (31 loc) · 1.33 KB
/
linkedin_profile_test.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
<?php
/**
* Example code to parse a LinkedIn profile using the LinkedInProfile class
*
* @author Guillaume Viguier-Just <[email protected]>
*/
require_once(dirname(__FILE__).'/linkedin_profile.php');
$profile = new LinkedInProfile('guillaumev', 'fr');
echo 'Your profile: <br />';
echo 'First name: '.$profile->firstname.'<br />';
echo 'Last name: '.$profile->lastname.'<br />';
echo 'Current status: '.$profile->current_status.'<br />';
echo 'Current locality: '.$profile->current_locality.'<br />';
echo 'Skills: '.$profile->skills.'<br />';
echo 'Interests: '.$profile->interests.'<br />';
foreach($profile->experiences as $experience) {
echo 'Experience: <br />';
echo ' '.$experience->title.'<br />';
echo ' <a href="'.$experience->organization->link.'">'.$experience->organization->name.'</a><br />';
echo ' '.$experience->organization->sector.'<br />';
echo ' '.$experience->period->start.' to '.$experience->period->end.'<br />';
echo ' '.$experience->description.'<br />';
}
foreach($profile->education as $education) {
echo 'Education: <br />';
echo ' '.$education->title.'<br />';
echo ' '.$education->degree.'<br />';
echo ' '.$education->major.'<br />';
echo ' '.$education->period->start.' to '.$education->period->end.'<br />';
echo ' '.$education->notes.'<br />';
}