Deep Link to LexisNexis Quicklaw [but Hurry]

Deep linking seems like such a no-brainer but it also seems not to be common knowledge.  If you have an electronic database, rather than sending the researcher through a series of menus or lookup charts, you can give them a link to the discrete folder of information they want to use.  For example, if I want to do real estate research, I may want to use just the case law books that include real estate cases, not also the ones with automobile negligence cases.

Serendipitously, I was wanting to do a bit of simple programming.  Simple because I was learning it and just needed a project to apply it to.  I contacted our friendly LexisNexis Canada rep and she helped me out by sending an internal database of some links that they have created already.  The data is not comprehensive but represented links that had already been created (which I assume was because they had been requested).  I was able to use this as the basis for creating a Javascript-powered deep link tool.

Preparing the Data

It was an interesting process.  The first thing was to go through the spreadsheet and collapse all of the workbooks to a single page.  Done.  Then I compared all of the deep links and found that there many commonalities.  In fact, there were just 3 types of links:

  • A link for searching a resource;
  • A link for browsing resources that aren’t forms;
  • A link for browsing forms.

The next step was to make each part of the link as reusable as possible.  I’ve tried to document the script as well as possible, so this is how it’s set up:

/* Each resource array has 7 possible elements.  They all share:
/* [0] Resource name
/* [1] What function the deep link goes to: search or browse
/* [2] A label about the content type
/* [3] The form element
/* [4] The form name
/* [5] The database source ID number
/* and if it is one of Forms & Precedents resources,
/* [6] an additional number.  For other resources, I’ve entered a zero.
/* The links are formed as follows:
/* Search:  ‘URL’ + deepLinkResource[3] + ‘sfi=’ + deepLinkResource[4] + ‘&csi=’ + deepLinkResource[5]
/* Browse:  ‘URL’ + deepLinkResource[3] + ‘sfi=’ + deepLinkResource[4] + ‘/verb=toc&csi=’ + deepLinkResource[5]
/* Forms:   ‘URL’ + deepLinkResource[3] + ‘pap=srcdir&csi=’ + deepLinkResource[5] + ‘&rand=’ + deepLinkResource[6]

The URL is the reusable part of the URL that includes the publisher’s site, etc.

It is not difficult to find these elements. [0] is whatever you want it to be. [1] is what you are going to do.  [2] is what the content is – form, etc. [3] is one of a few items that I should probably have re-used, but they don’t quite match up nicely to search v. browse.

[4] is the search or browse form you want to use.  You can find that by going to the search form for the database source, right-click and choose view source, and locating the form ID:


I usually do a CTRL-F on “formid” and locate it that way.

[5] is the source ID.  It’s easiest to find by going to the list of database sources and clicking on the little information i next to your database source name.  When the window pops up with the scope note, the source ID is at the end of the little window’s URL, after csi=:


So I’m grateful for the LexisNexis folks in providing me with the starter, which saved me a ton of time in getting started.  But it’s easy to add them or create your own once you’ve started.

My original goal had not been to create this with Javascript.  In fact, I’d been thinking about doing it using XML, an XSLT, and then just leave the Javascript to create the form.  But I had more fun with Javascript in this case and was again able to use an array of arrays.

The end result was a form that, when you select from the drop down the type of content you want, it will populate with the link.  One to click to test, one to highlight and cut and paste.

LexisNexis Quicklaw deep link generator.  THIS MAY NOT WORK WITH LEXISNEXIS ADVANCE so caveat emptor.

LexisNexis Quicklaw deep link generator. THIS MAY NOT WORK WITH LEXISNEXIS ADVANCE so caveat emptor.

Feel free to use the form or take it and make it your own.  As I say, it’s pretty well documented so it would be easy to add resources if people ask for ones that aren’t include.  Keep in mind that as LexisNexis moves to its new Advance platform, these links may all fail.

If I take another stab at this – and I may, once the Advance product rolls out in Canada – I would probably:

  • shift the array of arrays into a JSON file, which would still be accessible to the Javascript but potentially faster – it would certainly make the main form page load faster;
  • move the whole thing to PHP and MySQL, using a proper database.  There’s no particular benefit to doing that – and it would be harder to share – but (a) it would work with this site better and (b) I could create an administrative tool for adding or removing database sources.


Leave a Reply

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