This question about Using an extension: Answered

Dynamic referencesTopic

Hi there,

Can actually referencesTopic be dynamic? For instance, for each bibliography entry I create a separate page, e.g. ArticleEntryAUTOINC1001 (to attach various versions of an article as pdf, latex etc). Then in a dedicated topic, e.g. BibliographyTable, I can create a table of all ArticleEntryAUTOINC1001 entries with %SEARCH% selection. This will generate dynamic table of all my entries, where first cell can be a citation key.
  • If I now specify my BibliographyTable as referencesTopic - will it work?
  • Is there a way to make it working
Thanks.

-- ValentinKozlov - 12 Oct 2011


The Bibliography bit I don't know about but SEARCH can be like this:

| *TOPIC* | *SOMEFIELD* |
%SEARCH{ "name=~'ArticleEntry\d+'" type="query" format=" | $topic | $formfield(AnyField) |" }%


Here's a patch that might help (untested):

diff --git a/BibliographyPlugin/lib/Foswiki/Plugins/BibliographyPlugin/Core.pm b/BibliographyPlugin/lib/Foswiki/Plugins/BibliographyPlugin/Core.pm
index a636a85..f326815 100644
--- a/BibliographyPlugin/lib/Foswiki/Plugins/BibliographyPlugin/Core.pm
+++ b/BibliographyPlugin/lib/Foswiki/Plugins/BibliographyPlugin/Core.pm
@@ -373,6 +373,8 @@ sub _parseBibliographyTopics {
             my $text = $topicObject->text();
 
             if ($text) {
+                require Foswiki::Func;
+                $text = Foswiki::Func::expandCommonVariables( $text, $topic, $web, $topicObject );
 
                 # Use a $fh rather than loope over a split(/[\r\n]+/
                 # ... so we save a little memory

Please raise a task at BibliographyPlugin if you need more help.

For what it's worth, we're trying to get SemanticLinksPlugin working as a SEARCHable replacement for BibliographyPlugin, for example: http://testwiki.trin.org.au/Mangroves/Bibliography/, http://testwiki.trin.org.au/Mangroves/Ceriops_australis

This-work-in-progress can be found at http://trac.foswiki.org/browser/trunk/BibtexFormfieldPlugin/ or http://svn.foswiki.org/trunk/BibtexFormfieldPlugin/

-- PaulHarvey - 29 Oct 2011

QuestionForm edit

Subject Using an extension
Extension BibliographyPlugin
Version Foswiki 1.1.3
Status Answered
Related Topics
Topic revision: r3 - 29 Oct 2011, PaulHarvey
The copyright of the content on this website is held by the contributing authors, except where stated elsewhere. See Copyright Statement. Creative Commons License    Legal Imprint    Privacy Policy