357 Lotus blogs updated hourly. Who will post next? Home | Downloads | Events | Pods | Blogs | Search | myPL | About 
 
Latest 7 Posts
IconUK
Thu, Sep 4th 2014 134
Internationalization of the Pager controls
Mon, Sep 1st 2014 92
Tip of the day: isDocument() for nested data in the Data View control
Wed, Aug 13th 2014 145
Handsons from EntwicklerCamp 2014
Mon, Aug 11th 2014 124
Presentations from EntwicklerCamp 2014 – Track 4
Mon, Aug 11th 2014 165
Presentations from EntwicklerCamp 2014 – Track 3
Mon, Aug 11th 2014 154
Presentations from EntwicklerCamp 2014 – Track 2
Mon, Aug 11th 2014 203
Top 10
Comparison between Extension Library (OpenNTF) and Upgrade Pack 1 (IBM) – You’re help is appreciated
Tue, May 21st 2013 718
CALENDARIO: A responsive calendar plugin
Mon, Apr 8th 2013 480
5 weeks of XPages
Thu, Jul 3rd 2014 348
#oldschool @formula to check for attachments
Mon, Apr 7th 2014 333
New app in town: Rooms & Connections
Mon, Jun 16th 2014 313
Capturing geodata in XPages
Fri, Nov 1st 2013 295
jQCloud gone bad (jQuery Tag Cloud plugin in XPages)
Tue, Apr 9th 2013 279
New project on OpenNTF: DB Manager Notifier
Wed, Jul 2nd 2014 257
Navbar with dropdown menu from Notes view in Twitter Bootstrap (with XPages)
Fri, May 31st 2013 253
Using Teamroom 8.5.2 – recommended documentation?
Mon, Mar 21st 2011 234


Working with LinkedIn in XPages – People Search
Patrick Kwinten    

Here is another example for accessing LinkedIn’s API’s in XPages. This example contains code for performing a people search within your network.

I will include the example later in the next release of LinkedIn controls.

<?xml version=”1.0″ encoding=”UTF-8″?>
<xp:view xmlns:xp=”http://www.ibm.com/xsp/core”
xmlns:xc=”http://www.ibm.com/xsp/custom” createForm=”false”>
<head>
<title>LinkedIn JavaScript API Sample Application</title>
<xc:ccLinkedInAPIKey key=”//your  domain key here”></xc:ccLinkedInAPIKey>
<script type=”IN/Login”></script>
<xp:scriptBlock id=”scriptBlock3″>
<xp:this.value><![CDATA[function PeopleSearch() {
// Call the PeopleSearch API with the viewer's keywords
// Ask for 4 fields to be returned: first name, last name, distance, and Profile URL
// Limit results to 10 and sort by distance
// On success, call displayPeopleSearch(); On failure, do nothing.
var keywords = dojo.byId("#{id:searchBox}").value;
IN.API.PeopleSearch()
.fields('firstName', 'lastName', 'distance', 'siteStandardProfileRequest')
.params({'keywords': keywords, 'count': 10, 'sort': 'distance'})
.result(displayPeopleSearch)
.error(function error(e) { /* do nothing */ }
);
}]]></xp:this.value>
</xp:scriptBlock>
<xp:scriptBlock id=”scriptBlock4″>
<xp:this.value><![CDATA[function displayPeopleSearch(peopleSearch) {
var div = document.getElementById("peopleSearchResults");
div.innerHTML = "<ul>";
// Loop through the people returned
var members = peopleSearch.people.values;
for (var member in members) {

// Look through result to make name and url.
var nameText = members[member].firstName + ” ” + members[member].lastName;
var url = members[member].siteStandardProfileRequest.url;

// Turn the number into English
var distance = members[member].distance;
var distanceText = ”;
switch (distance) {
case 0: // The viewer
distanceText = “you!”
break;
case 1: // Within three degrees
case 2: // Falling through
case 3: // Keep falling!
distanceText = “a connection ” + distance + ” degrees away.”;
break;
case 100: // Share a group, but nothing else
distanceText = “a fellow group member.”;
break;
case -1: // Out of netowrk
default: // Hope we never get this!
distanceText = “far, far, away.”;
}
div.innerHTML += “<li><a href=”" + url + “”>” + nameText +
“</a> is ” + distanceText + “</li>”
}
div.innerHTML += “</ul>”;
}]]></xp:this.value>
</xp:scriptBlock>

</head>

<h1>Find People on LinkedIn</h1>
<xp:inputText id=”searchBox” defaultValue=”xpages”></xp:inputText>
<xp:button value=”Search” id=”button1″>
<xp:eventHandler event=”onclick” submit=”false”>
<xp:this.script><![CDATA[
PeopleSearch();]]></xp:this.script>
</xp:eventHandler>
</xp:button>
<div id=”peopleSearchForm”></div>
<div id=”peopleSearchResults”></div>
</xp:view>

Custom control ccLinkedInAPIKey you can find in the LinkedIn controls project.

Without any styling your result could look something similar like this:




---------------------
http://quintessens.wordpress.com/2012/03/20/working-with-linkedin-in-xpages-people-search/
Mar 20, 2012
64 hits



Recent Blog Posts
134


IconUK
Thu, Sep 4th 2014 4:06a   Patrick Kwinten
I think I have made all arrangements to attend the upcoming Icon UK event. Looking forward to this event and I hope to C U there! Take Our Poll (function(d,c,j){if(!d.getElementById(j)){var pd=d.createElement(c),s;pd.id=j;pd.src='http://s1.wp.com/wp-content/mu-plugins/shortcodes/js/polldaddy-shortcode.js';s=d.getElementsByTagName(c)[0];s.parentNode.insertBefore(pd,s);} else if(typeof jQuery !=='undefined')jQuery(d.body).trigger('pd-script-load');}(document,'script','pd-polldaddy-loade [read] Keywords: javascript
92


Internationalization of the Pager controls
Mon, Sep 1st 2014 5:45a   Patrick Kwinten
While translating an app for internationalization I noticed that Pager controls (e.g Pager Expand/Collapse, Pager Show/Hide Details)) were still default in English. So I wondered how you could translate them since they did not adapt to the selected language in my browser? It turns out that a workable way is to set the text explicit in the controls first to your default application language: Now they have become available for translation: If you open the properties file for the XPage/Custom C [read] Keywords: xpages application properties wiki
145


Tip of the day: isDocument() for nested data in the Data View control
Wed, Aug 13th 2014 5:05a   Patrick Kwinten
You can show nested data in the details section of the Data View control. Read about it here: Data Views – Part 10: Nested Repeat in the Detail Section. In case you have a ‘flat’ Data View (one without collapisble categories) you do not need to detect if your ‘var’ property is a document. But when you have a categorized Data View you better check it otherwise opening/closing categories will give an error… [read] Keywords: xpages
124


Handsons from EntwicklerCamp 2014
Mon, Aug 11th 2014 6:25a   Patrick Kwinten
Subject Download Presentation Javascript – Die ersten Schritte http://www.entwicklercamp.de/konferenz/ent2014.nsf/bc36cf8d512621e0c1256f870073e627/aa9f566f61ab0287c1257be200295c9d/$FILE/H1-Javascript_HandsOn_1_0_0.pdf Lotuscript – die ersten Schritte http://www.entwicklercamp.de/konferenz/ent2014.nsf/bc36cf8d512621e0c1256f870073e627/4865dda7cb38ffc0c1257be200295ca0/$FILE/H2-LotusScript.pdf Formeln – die erste Schritte http://www.entwicklercamp.de/konferenz/ent2014.nsf/bc3 [read] Keywords: domino lotusscript notes xpages javascript
165


Presentations from EntwicklerCamp 2014 – Track 4
Mon, Aug 11th 2014 6:05a   Patrick Kwinten
Track Session Subject Download Presentation Track4 Session1 The Road to Damascas – LS and @Formula to SSJS http://www.entwicklercamp.de/konferenz/ent2014.nsf/bc36cf8d512621e0c1256f870073e627/ddd7b3baaf49dbadc1257be200295cc1/$FILE/T4S1-Xpages-road%20to%20damascas.pdf Track4 Session2 Wo speichert Notes was? Und was kann der Entwickler damit anfangen? http://www.entwicklercamp.de/konferenz/ent2014.nsf/bc36cf8d512621e0c1256f870073e627/2071360f70207a00c1257be200295cbf/$FILE/T4S2-Wo%20speich [read] Keywords: domino notes xpages development java
154


Presentations from EntwicklerCamp 2014 – Track 3
Mon, Aug 11th 2014 5:45a   Patrick Kwinten
Track Session Subject Download Presentation Track3 Session1 LotusScript Best-Practices (“keep it simple”) http://www.entwicklercamp.de/konferenz/ent2014.nsf/bc36cf8d512621e0c1256f870073e627/60c08dbd3c75cf5fc1257be200295cba/$FILE/T3S1-Lotusscript.pdf Track3 Session2 Java Beans sind kompliziert? Nicht die Bohne! http://www.entwicklercamp.de/konferenz/ent2014.nsf/bc36cf8d512621e0c1256f870073e627/1a9601442b32b155c1257be200295ca6/$FILE/T3S2-JavaBeans.pdf Track3 Session3 OpenNTF R [read] Keywords: connections ibm lotusscript xpages java javascript openntf
203


Presentations from EntwicklerCamp 2014 – Track 2
Mon, Aug 11th 2014 5:25a   Patrick Kwinten
Track Session Subject Download Presentation Track2 Session1 IBM Connections http://www.entwicklercamp.de/konferenz/ent2014.nsf/bc36cf8d512621e0c1256f870073e627/e76eba65a7777a5fc1257be200295cc3/$FILE/T2S1-IBM%20Connections.pdf Track2 Session2 XPages und Connections http://www.entwicklercamp.de/konferenz/ent2014.nsf/bc36cf8d512621e0c1256f870073e627/3ce43336a0c21017c1257be200295cb1/$FILE/T2S2-Xpages%20und%20Connections.pdf Track2 Session3 iNotes deep dive http://www.entwicklercamp.de/konferen [read] Keywords: connections ibm inotes notes xpages database java security
197


Presentations from EntwicklerCamp 2014 – Track 1
Mon, Aug 11th 2014 4:05a   Patrick Kwinten
Track Session Subject Download Presentation Track1 Session1 XPages – 1 – Notes-Daten auf das Smartphone oder Tablet – Datenaustausch zwischen nativen mobilen Anwendungen und Domino mit Hilfe von XPage http://www.entwicklercamp.de/konferenz/ent2014.nsf/bc36cf8d512621e0c1256f870073e627/8138c341016c7bd7c1257be200295caa/$FILE/T1S1-Notes-Daten-1.pdf Track1 Session2 XPages – 1 – Notes-Daten auf das Smartphone oder Tablet – Datenaustausch zwischen nativen mobilen [read] Keywords: domino notes xpages
348


5 weeks of XPages
Thu, Jul 3rd 2014 6:45a   Patrick Kwinten
Counting the hours before vacation starts. Looking forward to reading some good summer reading… Enjoy your summer! [read] Keywords: xpages
257


New project on OpenNTF: DB Manager Notifier
Wed, Jul 2nd 2014 9:05a   Patrick Kwinten
Today I created a new project on OpenNTF called ‘DB Manager Notifier‘. The application is a tool that can send periodically notifications to persons who are listed as Manager in an Application document in the catalog.nsf on your IBM Domino server. A typical use case is a Development or Sandbox environment where users are free to install new applications. In such loosely managed environments people tend to “forget” their applications and leave them installed on the server. [read] Keywords: agent domino ibm application applications development openntf server




Created and Maintained by Yancy Lent - About - Blog Submission - Suggestions - Change Log - Blog Widget - Advertising - Mobile Edition