Display EBSCO Discovery Results in Block Instead of Page

We encourage users to post events happening in the community to the community events group on https://www.drupal.org.
mpruitt's picture

Cheers everyone.

EBSCO provides a Drupal module that will display results from EBSCO on a custom page http://mysite/ebsco/results.

There is a template preprocess function for the page, and a tpl.php file for the page.

Instead of displaying the page, I want to load the results into a custom block. I'm using the API call of
drupal_form_submit('my_form_name', $form_state) to make the submit call. I set the $form_state['variables'] as below before making the call:

// set $form_state array values
$form_state = array();
$form_state['values']['lookfor'] = $search;
$form_state['values']['type'] = 'AllFields';
$form_state['values']['op'] = t('Search');

I don't get any errors when I check after the submit with form_get_errors(), but I can't find any results to pull into the custom block.

Has anyone else tried to do something similar to this with the EBSCO module?

Comments

Not an answer, but a question

dbourrion's picture

Hi
Didn't know about that Ebsco module, and I can't find it on the web.
Should you give me an url to that module, or more information ?

Thanks
D.

PS : so in fact, on the question "Has anyone else tried to do something similar to this with the EBSCO module?" I can only respond "no" :((

Update

mpruitt's picture

Hello everyone, I thought it would be appropriate to post an update on this topic.

The library I am working with is the Richland Library in Columbia, SC. Kelly Coulter is the Virtual Services Manager with overall responsibility for the web site, and Mark Jarrell is the Online Applications Developer.

Kelly and Mark decided to use a Bento Box approach, where results from various resources were displayed in a Bento Box like display.

Mark created a custom Bento Boxes module to direct all search results to the appropriate blocks.

If you go to http://richlandlibrary.com and enter a search in the top box, you'll see the Bento Boxes displaying the results.

The block labeled "Read It Online" contains the results from EBSCO. Click on the "View xxx more results" link at the bottom to go to the feature page for EBSCO results.

To achieve the desired out put we heavily modified the ebsco.module and several of the /template/.tpl.php files.

EBSCO usually displays meta data for search results without requiring a login. RL wanted to be able to show full results to anyone inside of their libraries, so we added so custom code to determine location based on IP.

Mark led an internal and external team that achieved some really nice results.

If anyone is using EBSCO, and would like more information, a good first step would be to contact your EBSCO account rep and let them know you'd like to learn more about how Richland Library used the EBSCO module in their search project.

Mark Pruitt
Developer of The Linux Foundation (retainer)
Columbia, SC area

Update 2

mpruitt's picture

Hello again,

Several have contacted me asking about how to get the EBSCO module. My apologies for not including that information before.

To get the module you'll need to have a login for the EDS Wiki at http://edswiki.ebscohost.com/EBSCO_Discovery_Service_Wiki.

You can create an account at the same page if you don't have one. The account is free, and takes about 24-48 hours to get set up for access once you create it.

Once you can login, go to this page: http://edswiki.ebscohost.com/EBSCO_Discovery_Service_Wiki. On that page, find "Download Drupal Source Code" on the page to get the module.

To use the module on your site, you'll need a few credentials from your EBSCO representative.

If you wish, you can also use the EBSCO Drupal Demo, found on the same page as the download link above.

Mark Pruitt
Developer of The Linux Foundation (retainer)
Columbia, SC area

Error with EBSCO Drupal Module

John Mark Fajardo's picture

Hi @Mark in SC_USA,

I've tried the module, I also supplied the required fields on the configuration page but after going to this link http://example.com/ebsco/fulltext/ it returns this error: "Fatal error: Cannot use object of type EBSCOException as array in ../sites/all/modules/ebsco/lib/EBSCORecord.php on line 394". I don't know what was going on but EBSCO's drupal module doesn't work for me. Any help will be appreciated.

Thanks.

John Mark Fajardo
Web Developer
Mis. Occ., Philippines

Hey John, we ran into that

mpruitt's picture

Hey John, we ran into that problem at the Richland Library as well.

Mark Jarrell who is actually the Online Application Developer at the library did the work for it. I'll ask him to take a look at the post and reply.

Mark Pruitt
Developer of The Linux Foundation (retainer)
Columbia, SC area

Thank you, that would be very

John Mark Fajardo's picture

Thank you, that would be very helpful.

John Mark Fajardo
Web Developer
Mis. Occ., Philippines

This looks slightly different

attheshow's picture

This looks slightly different than what I was running into. We had an issue in EBSCODocument.php where inside of the search() function, $this->results was being returned as an object if there was an error or no results were returned. Since $this->results is normally an array, I used Watchdog to log the error and then re-cast it as an array to prevent the application error. I basically added this at the end of that function:

if (is_object($this->results)) {
  watchdog('Ebsco', 'Search failure. Response from EDS was: ' . $this->results, array(), 'WATCHDOG_ERROR');
  $this->results = (array) $this->results; // If it's an empty object, re-cast it as an array to prevent errors.
}

Mark W. Jarrell
Online Applications Developer
Richland Library
http://www.richlandlibrary.com
http://fleetthought.com
Twitter: attheshow

Contact EBSCO Support

mpruitt's picture

John, send an email to support@ebsco.com.

If you have a plain vanilla install of their module, you shouldn't be getting errors.

Be as detailed about the use of the module, and what you are doing when the error occurs as possible.

Mark

Mark Pruitt
Developer of The Linux Foundation (retainer)
Columbia, SC area

Thanks for the help

John Mark Fajardo's picture

Hello Mark,

Thanks for the help.

I will try sending an email to support@ebsco.com and also I would like to apply the code suggestion from Mark Jarrell.

Cheers.

John Mark Fajardo
Web Developer
Mis. Occ., Philippines

Drupal 7

Pierre Naegelen's picture

Hi Mark,
Is this module compatible with Drupal 7 ?
Cheers;
P

Pierre Naegelen
Responsable du Service des Ressources Électroniques
Administrateur de contenus site web
Service Commun de la Documentation
Université Paul Sabatier Toulouse III

Yes, the Ebsco module is

attheshow's picture

Yes, the Ebsco module is available for Drupal 7, but is only available from them (with an assigned account from Ebsco) here: http://edswiki.ebscohost.com/EBSCO_Discovery_Service_API_Sample_Applicat...

Mark W. Jarrell
Online Applications Developer
Richland Library
http://www.richlandlibrary.com
http://fleetthought.com
Twitter: attheshow

Cannot use object of type EBSCOException...

givingxsharing's picture

Hello all,
We ran into a similar issue with this module, downloaded it from GitHub a few days ago and got this error when searching:

Cannot use object of type EBSCOException as array in /var/www/html/sites/xxxx/modules/ebsco/lib/EBSCODocument.php on line 275.

The search result blanks out with 500 Internal error.

Any help is greatly appreciated! Thanks!

RE:

pshowell's picture

Does your module folder have the correct security permissions? Sometimes that usually trips me up.

Libraries

Group organizers

Group categories

Resources

Group notifications

This group offers an RSS feed. Or subscribe to these personalized, sitewide feeds:

Hot content this week