Learn how easy it is to sync an existing GitHub or Google Code repo to a SourceForge project! See Demo

Close

Saving citations

Help
Jens
2010-03-30
2013-05-28
  • Jens
    Jens
    2010-03-30

    Hi there!

    Please excuse me, but I am not familiar with citations. I am expecting  a relationship between the cite options ( use custom text citation format) and the rtf-file I get via 'Save Citations'-Cite-Button. But it does not matter if I change anything in the user-options, the resulting rtf-file always looks the same. :-(

    could someone give me a hint?

    Thank you,
    Jens

     
  • Florian
    Florian
    2010-03-30

    hi there,

    the citation style changes when you're in Citation-View mode. OK, first step is to go into the options and mark all the citation formats that you want to use. then you go back to your library, and klick the button "Citation View" (usually this is next to Collumn View and Details). Now you have to open the drop-down menu on the left-hand side called "Search&Display Options". In this menu you can choose the citation style you wanna use, hit the display button and the page reloads changing the style accordingly. The style should be saved in the exported RTF file as well. Notice that the "Seach&Display Options" Menu changes depending on in which mode you are in (details, collumn, citation)…

    Hope this helps.

     
  • Hi Jens,

    Florian already gave you a nice description of how to change a citation style in refbase.

    The option you mentioned ("use custom text citation format") refers to *in-text* citations. An in-text citation is the short signal phrase in your written text that often includes the author's name(s) and the publication year and which is used to refer to the full citation in your text's bibliography. refbase offers a citation style called "Text Citation" which can be used to generate an in-text citation string that matches your desired format. To adopt the formatting of in-text citations, you'd mark the checkbox next to "use custom text citation format" and specify a placeholder pattern that fits your desired in-text citation format. The placeholder syntax is described at:

    http://placeholders.refbase.net/

    HTH, Matthias

     
  • Jens
    Jens
    2010-03-31

    Thank you Florian & Matthias,

    now I have a starting-point to get a list without editing a styles-php-file.
    Is it possible to get the abstract into the citation?

    Jens

     
  • Hi Jens,

    Is it possible to get the abstract into the citation?

    Not with the default list of citation styles when outputting to non-HTML formats, though it should be possible to add that functionality to one of the PHP style files.

    Another option would be to click the print icon when in Citation view, then toggle the little widget underneath each citation to display all the abstracts that you'd like to see, and copy that list (or print  it to a PDF etc).

    But it really depends on what you're trying to achieve, so you might want to describe in more detail your envisioned workflow.

    Matthias

     
  • Jens
    Jens
    2010-03-31

    Hi Matthias,

    we are using refbase to manage all kind of information materials (reports, maps etc.) for our work. I am looking for a simple way creating material-lists with certain fields shown or hidden (user-specific). So the easy way via the custom text citation fits all my needs, except for the missing opportunity to add the abstract-field.

    Perhaps an easy cite-format-php-file would help. We do not need the dependencies from the type-field. I am afraid these dependencies make it difficult for me understanding the cite-format-php-files.

    BTW is there a possibility to export records to csv? Unfortunately Excel 2003 is not able to import the OpenOffice spreadsheet.

    Thank you
    Jens

     
  • Hi Jens,

    I am looking for a simple way creating material-lists with certain fields shown or hidden (user-specific).

    By "user-specific" you mean that the user should be able to show or hide particular fields before generating the report?

    And what output formats to you want/need? Do you need output to RTF or PDF? HTML output does already include the abstracts in citation view.

    So the easy way via the custom text citation fits all my needs, except for the missing opportunity to add the abstract-field.

    I see. We might think about adding <:abstract:> as a supported placeholder.

    Perhaps an easy cite-format-php-file would help.

    Please have a look at file 'cite/styles/cite_TextCitation.php'. This file should be easy to modify. You can add any field there. As an example, to add the 'abstract' field underneath the record's text citation string, replace this line:

    $record = parsePlaceholderString($formVars, $textCitationFormat, $fallbackPlaceholderString);
    

    with these two lines:

    $record = parsePlaceholderString($formVars, $textCitationFormat, $fallbackPlaceholderString);
    $record .= $markupPatternsArray["newline"] . $markupPatternsArray["newline"] . $row['abstract'] . $markupPatternsArray["newline"] . $markupPatternsArray["newline"];
    

    The $markupPatternsArray stuff is to achieve a more pleasing result for RTF and PDF output, but you can of course adopt this to your needs.

    BTW is there a possibility to export records to csv?

    Unfortunately not, but it shouldn't be too difficult to generate a CSV output if desired. Let me know if you require help with this. But maybe the above option is the better approach anyway?

    HTH, Matthias

     
  • Sorry for the garbled code lines in my previous post, the SourceForge forum software seems to have problems with it.

    What I meant was simply to add this code (all on a single line):

    $record .= $markupPatternsArray . $markupPatternsArray . $row . $markupPatternsArray . $markupPatternsArray;

    after the line that starts with:

    $record = parsePlaceholderString(…

    Matthias

     
  • Well, the SourceForge forum software still garbles the code (it lacks some parts). :-(

    $row

    should be

    $row

    without the spaces. If you follow this discussion via email, the code is displayed there correctly.

    Sorry for the trouble, Matthias

     
  • Jens
    Jens
    2010-03-31

    Somehow, I screwed it! :-)

    Should I replace line 56 or add the code after line 56? Because now I just got the Abstract and nothing else.

    As a side-effect I am now able to add my own citation styles! ;-)

    Jens

    PS: You are offering the way best support for any open source project I know. Thank you!

     
  • Jens
    Jens
    2010-03-31

    If you follow this discussion via email, the code is displayed there correctly.

    I deleted them 5 minutes before your post! :'(

     
  • Hi Jens, thanks for the kind words, we appreciate it!

    Should I replace line 56 or add the code after line 56?

    Simply *add* the line I've given (the one that starts with $record .= $markupPatternsArray…) after line 56.

    That should do the trick, Matthias

     
  • Jens
    Jens
    2010-03-31

    It works out fine, thank you very much!

    I dumped some of your earlier queries…

    I am looking for a simple way creating material-lists with certain fields shown or hidden (user-specific).

    By "user-specific" you mean that the user should be able to show or hide particular fields before generating the report?

    Yes, that was my goal. The user can now manipulate the text citation via user-options and choose whether the abstract is shown or not by using the two different Text Citation-Styles. I think we will have to reformat the list in Word anyway, so the lack of format in the Text Citation-Style does not bother me.

    And what output formats to you want/need? Do you need output to RTF or PDF? HTML output does already include the abstracts in citation view.

    RTF is alright as we are using Word. PDF might be useful, too.

    BTW is there a possibility to export records to csv?

    Unfortunately not, but it shouldn't be too difficult to generate a CSV output if desired.

    I think an easy search and replace with the rtf-output in notepad++ should generate a suitable csv-file. Perhaps I can come back to this point later if it's necessary.

    Jens

     
  • BTW is there a possibility to export records to csv? Unfortunately Excel 2003 is not able to import the OpenOffice spreadsheet.

    You can use Sun's ODF plugin for MS Office (or
    MS's plugin).  There are also a number of free/open source converters.  You could potentially run one on your server (and write a relatively simple export script) if CSV output is something you'll commonly want.

     
  • Jens
    Jens
    2010-03-31

    Somehow the Sun-Plugin didn't work out well. I just don't know in which context. I am using the odf-converter hosted on sourceforge, but it stops the conversion with an error. I never tried another converter…

    Jens

     
  • Jens
    Jens
    2010-03-31

    but it stops the conversion with an error

    … the conversion of the odf XML exported records. Oher documents work out well.

    Jens