ORCID Researcher Lookup Widget V2

What is this widget?

The ANDS ORCID Widget allows you to enhance your web form to include the ability to lookup and search for an ORCID ID.

This widget is powered by the ORCID JSONP API and requires jQuery to function.

How to use this widget

Before you start! While optional, ANDS recommends that you register for a free API key to be used with this widget. Registering will allow us to keep you informed of changes and planned outages to our services, as well monitor the system for quality purposes.

Note that if you have previously registered for an API key you do not need to register again. Your ANDS API key is reusable with any of our widgets and services.

Put the following code snippet into your HTML document between the <head> tags.

<script src="//ajax.googleapis.com/ajax/libs/jquery/1.8.2/jquery.js"></script>
<script type="text/javascript" src="//researchdata.ands.org.au/apps/assets/orcid_widget/js/orcid_widget_v2.js"></script>
<link rel="stylesheet" type="text/css" href="//researchdata.ands.org.au/apps/assets/orcid_widget/css/orcid_widget_v2.css" />

And you’re done! Just 3 lines of code! Any input fields on your page which have the class orcid_widget will be transformed into a fully-functional ORCID lookup tool.



This example shows how to embed a Researcher Lookup tool into your webpage.

  • if you don’t know your ORCID, click Search to search for your ORCID profile
  • if you already know your ORCID, put it into the text field and click Lookup instead



Example 1

In this example, we initialise the widget using some custom settings:

  • the labels on the page have been changed (see the JS tab)
  • automatically display the search box when the widget loads
  • a default value for the ORCID has been set in the HTML tab (and this is displayed when the page loads)

Example 2

Another example where we initialise the widget using custom settings (see the JS tab):

  • Set styling of the search form div
  • Set styling of the orcid information div

Note: You will need to add the supplied classes to your style sheet to apply formatting.

Example 3

Another example where we initialise the widget using custom settings (see the JS tab)

  • Enable tooltip of full information on mouseover of the results list

Note: This feature requires the qtip jquery plugin to be installed to display correctly.


The widget can be initialised by two methods:

  • Simple Mode: add the class="orcid_widget" api_key="[[your_api_key]]" to a <div> or <input> element as illustrated in the examples above.
  • Custom Mode: initialise the registry_widget from javascript (jQuery) by calling $('#id_of_your_container_element').orcid_widget();. You can pass any of the below parametersto the orcid_widget() function to customise its behaviour.
Property Description Default
search_endpoint JSONP search API for ORCID http://pub.orcid.org/search/orcid-bio?q=
lookup_endpoint JSONP API for ORCID Lookup service http://pub.orcid.org/
api_key Your pre registered api key which will uniquely identify the widget user public
pre_lookup Automatically Do a lookup on the current value of the input field false
search Display Search Button, enable searching functionality true
pre_open_search Open Search Box by default false
search_text Text to display on the open search box button <i class="icon-search"></i> Search
search_class CSS class to apply on the open search box button orcid_search btn btn-small
lookup Display the Lookup button, enable Lookup functionality true
lookup_text Text for the lookup button Look up
lookup_class Lookup button CSS class orcid_lookup btn btn-small
before_html: Text to display before the input field <span class="orcid_before_html">http://orcid.org/</span>
wrap_html The wrapping HTML to cover the input fields <div class="orcid_wrapper"></div>
result_success_class CSS class for the div displaying successful lookup orcid_success_div
result_error_class CSS class for the div displaying error lookup orcid_error_div
search_div_class CSS class for the searching div orcid_search_div
nohits_msg Message to display when no result or an error returns <p>No matches found<br/>
If you wish to register for an
orcid please click
<a href="https://orcid.org/register" target="_blank">here</a></p>
query_text Text displaying before the search query Search Query:
search_text_btn Text display for the search button Search
close_search_text_btn Text display for the closing search div button [x]
lookup_error_handler overwrite function for error lookup function(xhr, message) false
lookup_success_handler overwrite function when a successful lookup returnsfunction(data, obj, settings) false
post_lookup_success_handler a function hook after a successful lookup returnsfunction(data, obj, settings) false
auto_close_search boolean, To automatically close the search box after a value is selected false
tooltip boolean To enable tooltip on mouseover of result list to display details. NOTE: jquery qtip module is required to use this feature false
info_box_class Text to set a class to style the individual results info-box
search_div_class Text to set a class to style the search form div orcid_search_div

Comments 2

  1. I’ve embedded your v.2 widget but wonder if there is a problem with it. I can lookup a researcher by his ORCID – 0000-0003-2852-7923 but if I search for him by name – Sean Hood – nothing is found. Is this something in the back end of ORCID itself or is it the widget code?

  2. Joel Benn Post author

    Hi Cheryl,

    Thanks for contacting us regarding this issue. After doing some investigation we discovered that we were not encoding the search string correctly when querying ORCID. We have implemented a hot fix to our production service and this should no longer be an issue for you. Please let us know if you have any further questions.


Leave a Reply

Your email address will not be published. Required fields are marked *

five − five =