Jump to content

Module:Citation/CS1: Difference between revisions

for config.CitationClass == "journal" reset empty URL to use PMC url if any.
m>Wikid77
(removed PMC url when empty URL.)
m>Wikid77
(for config.CitationClass == "journal" reset empty URL to use PMC url if any.)
Line 335: Line 335:
     local sepc = args.separator
     local sepc = args.separator


     if ( config.CitationClass == "citation" ) then sepc = "," end  
    if ( config.CitationClass == "journal" ) then
        if (URL == nil or URL == "") then
          if (PMC ~= nil and PMC ~="")
            then URL="http://www.ncbi.nlm.nih.gov/pmc/articles/PMC" .. PMC
            else URL=""
          end
        end
    end
     if ( config.CitationClass == "citation" ) then sepc = "," end
     if ( sepc == nil ) then sepc = "." end  
     if ( sepc == nil ) then sepc = "." end  
     if ( DeadURL == nil ) then DeadURL = "no" end
     if ( DeadURL == nil ) then DeadURL = "no" end
Line 686: Line 694:
         else ArchiveDate = "" end
         else ArchiveDate = "" end
         if ( "no" == DeadURL ) then
         if ( "no" == DeadURL ) then
             Archived = " [" .. ArchiveURL .. "  Archived] from the original on" .. ArchiveDate .. "."
             Archived = " [" .. ArchiveURL .. "  Archived] from the original on" .. ArchiveDate
         else
         else
             Archived = " Archived from [" .. args.url .. " the original] on" .. ArchiveDate .. "."
             Archived = sepc .. " Archived from [" .. args.url .. " the original] on" .. ArchiveDate
         end
         end
     else
     else
Anonymous user
Cookies help us deliver our services. By using our services, you agree to our use of cookies.