Download & Extend

Views citation handler does not remove BibTeX brackets

Project:Bibliography Module
Version:6.x-1.6
Component:Code
Category:bug report
Priority:critical
Assigned:Unassigned
Status:needs review

Issue Summary

Despite the fact that the biblio_hide_bibtex_braces setting is enabled.

Comments

#1

Status:active» needs review

This works for us.

Index: biblio/views/biblio_handler_citation.inc
===================================================================
--- biblio/views/biblio_handler_citation.inc    (revision 3877)
+++ biblio/views/biblio_handler_citation.inc    (working copy)
@@ -54,6 +54,11 @@

         $item->biblio_contributors = biblio_load_contributors($item->vid);
         $item->biblio_keywords = biblio_load_keywords($item->vid);
+        //EW_HACK
+        if (variable_get('biblio_hide_bibtex_braces', 0)) {
+          $item->title = biblio_remove_brace($item->title);
+        }
+        //END_OF_HACK
         $this->items[$vid] = $item;
       }
     }

#2

Status:needs review» fixed

Yep, that would work, I've added it to the code. The views support is still a moving target, so the same features are not guaranteed to exist yet.

Ron.
(http://drupal.org/cvs?commit=229746)

#3

Status:fixed» closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

#4

Version:6.x-1.5» 6.x-1.6
Status:closed (fixed)» needs review

Though the patch was committed, it seems like the functionality is not there. Does the 1.6 version of biblio not include this fix?

Thanks again for your time.

Daniele

#5

The code is there, you might want to check the "admin/settings/biblio" page in the "BibTex" section to make sure that the feature is turned on.

#6

The feature is turned on, but I believe it is a problem in the patch that you committed. Instead of getting the title from the item ($item->title), it was fetched from the node ($node->title). Hope that made sense. thanks again!

daniele

#7

Doh! Stupid mistake on my part, I'll fix that.

#8

Status:needs review» fixed

Ok, I've committed the fix.

#9

Status:fixed» closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

#10

Status:closed (fixed)» needs work

This is now an issue with bibtex 6.x-1.15 and Views 6.x-2.14. The braces are removed correctly at /biblio, but not when displayed by Views.

#11

Status:needs work» needs review

The attached patch fixes it.

AttachmentSize
502140-remove-bibtex-braces-with-views-11.patch 544 bytes
nobody click here