0.2.6 add archive.org link in doi resolver as shortcode's parameter

This commit is contained in:
ulaulaman 2018-02-05 18:43:44 +01:00 committed by GitHub
parent 2e141c8f4a
commit d127eff77d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 8 additions and 2 deletions

View File

@ -2,7 +2,7 @@
/*
Plugin Name: Citations tools
Description: The plugin add some shortcodes add a link to a paper using the doi code or to resolve doi code and publish a full citation apa formatted.
Version: 0.2.5
Version: 0.2.6
Author: Gianluigi Filippelli
Author URI: http://dropseaofulaula.blogspot.it/
Plugin URI: https://github.com/ulaulaman/citations-tools
@ -40,7 +40,8 @@ add_shortcode('ctdoiresolve', 'ctdoiresolve');
array(
'code' => null,
'arxiv' => null,
'pdfurl' => null
'pdfurl' => null,
'archiveurl' => null
),
$atts
)
@ -67,6 +68,11 @@ add_shortcode('ctdoiresolve', 'ctdoiresolve');
else
{$citation = $citation;}
if ( $archiveurl <> null )
{$citation = $citation.' (<a href="'.$archiveurl.'" target="archive">archive.org</a>)';}
else
{$citation = $citation;}
$results = $citation.'</p>';
return $results;