No COinS data added to items

Hi all,

I'm using version 2.1.2 and have the COinS plugin enabled (I tried dis-and-re-enabling it just in case), but no COinS info appears to be added to items, either on the individual page, or on browse pages. It's not visible in the HTML code, and Zotero treats the items as regular web pages with an abstract, ignoring creator, date, etc. This is true both in both admin and public views. I've not changed a thing in the admin theme, but I am using a slightly customized version of Berlin for the public site.

I gave the old advice in this post a whirl http://omeka.org/forums/topic/how-to-build-a-publications-page-academic-website
but it unsurprisingly didn't help. I'm not sure what hook to call where to fix the problem. My custom show.php is below; I have not modified browse.php.

<br />
<?php echo head(array('title' => metadata('item', array('Dublin Core', 'Title')),'bodyclass' => 'items show')); ?><br />
<div><br />
	<ul class="item-pagination navigation"><br />
        <li id="previous-item" class="previous"><?php echo link_to_previous_item_show(); ?><br />
        <li id="next-item" class="next"><?php echo link_to_next_item_show(); ?></p>
<p></div><br />
<div><h1><?php echo metadata('item', array('Dublin Core','Title')); ?></h1></div><br />
<div id="primary" style="float: left; width: 200px; margin-left:20px;"></p>
<p> <!-- Items File --><br />
	    <h3 style="margin-bottom:10px"><?php echo __('Files'); ?></h3><br />
    <div id="item-images"><br />
         <?php echo files_for_item(); ?><br />
    </div></p>
<p>    <!-- The following prints a citation for this item. --><br />
    <div id="item-citation" class="element"><br />
        <h3><?php echo __('Citation'); ?></h3><br />
        <div class="element-text"><?php echo metadata('item','citation',array('no_escape'=>true)); ?></div><br />
    </div></p>
<p>     <!-- The following prints a list of all tags associated with the item --><br />
    <?php if (metadata('item','has tags')): ?><br />
    <div id="item-tags" class="element"><br />
        <h3><?php echo __('Tags'); ?></h3><br />
        <div class="element-text"><?php echo tag_string('item'); ?></div><br />
    </div><br />
    <?php endif;?></p>
<p></div> <!-- End of Primary. --></p>
<p><!-- Begin Dublin Core. --><br />
<div id="secondary" style="float: left; display: inline; margin-left: 10px; width: 460px; margin-right: 0px;  padding-left: 10px;"><br />
    <div id="item-metadata"><br />
	    <?php echo all_element_texts('item'); ?><br />
    </div></p>
<p>   <?php if(metadata('item','Collection Name')): ?><br />
      <div id="collection" class="element"><br />
        <h3><?php echo __('Collection'); ?></h3><br />
        <div class="element-text"><?php echo link_to_collection_for_item(); ?></div><br />
      </div><br />
   <?php endif; ?></p>
<p>   <?php fire_plugin_hook('public_items_show', array('view' => $this, 'item' => $item)); ?></p>
<p></div> <!-- End of Secondary. --><br />
<div><br />
	<ul class="item-pagination navigation"><br />
        <li id="previous-item" class="previous"><?php echo link_to_previous_item_show(); ?><br />
        <li id="next-item" class="next"><?php echo link_to_next_item_show(); ?></p>
<p></div></p>
<p> <?php echo foot(); ?><br />

It would be really helpful if the plugin documentation included the code necessary to make themes COinS compatible, especially given the relatively sparse documentation for theming in 2.0 vs 1.x.

tl;dr: What code do I need to add to show.php and browse.php, and where do I need to add it?
Thanks!

You look like you already have the code you need on that page: fire_plugin_hook('public_items_show' ....

And yet, no author/date/etc fields in Zotero for me :(

Other Omeka sites, e.g. http://archives-bourbaki.ahp-numerique.fr/items/show/1 import the metadata just fine, so I don't think it's a Zotero issue.

Unfortunately I don't yet have a public address for the site. What other info could I provide to help figure this out?

It's a little hard to say without seeing what the generated markup looks like.

There's just no <span> at all being generated? It would appear near the bottom of the page.

Turns out that it does create the span, but the COiNS elements are not formatted properly.


<span class="Z3988" title="ctx_ver=Z39.88-2004&rft_val_fmt=info%3Aofi%2Ffmt%3Akev%3Amtx%3Adc&rfr_id=info%3Asid%2Fomeka.org%3Agenerator&rft.Creator=Kathleen+A.+Merrigan&rft.Date=28-Oct-1999&rft.Format=application%2Fpdf&rft.Source=Merrigan+Collection%2C+Box+10%2C+Folder+2&rft.title=Changes+to+proposal&rft.description=Many+of+the+annotated+documents+in+Dr.+Merrigan%27s+collection+include+doodles+in+addition+to+text.+This+one+features+a+Jack+o%27+Lantern.+&rft.type=document&rft.identifier=http%3A%2F%2Fomeka-dev.nal.usda.gov%2Fitems%2Fshow%2F231"></span>

If I change "Creator" to "au" and change all uppercase elements to lowercase (rtf.Date to rtf.date), Zotero correctly reads most of the metadata.

Huh. Thanks! We're double-checking against the spec, but at first glance it looks like just lowercasing everything works.

Yep. Fixed in the latest commit and will be officially released soon.

Excellent, thanks Patrick!