Module:Citation/CS1: திருத்தங்களுக்கு இடையிலான வேறுபாடு

உள்ளடக்கம் நீக்கப்பட்டது உள்ளடக்கம் சேர்க்கப்பட்டது
Treat PublicationDate as Date is Date is absent
Try to fix year handling for CITEREF
வரிசை 79:
function safeforurl( str )
return str:gsub('%[','['):gsub('%]',']'):gsub("\n", " ");
end
 
function selectyear( str )
local lang = mw.getContentLanguage();
local good, result;
good, result = pcall( lang.formatDate, lang, 'Y', str )
if good then
return result;
else
endreturn '';
end
end
 
வரி 905 ⟶ 916:
-- Now enclose the whole thing in a <span/> element
if ( Year == nil ) then
if ( DateIn =~= nil orand DateIn =~= "" ) then
then Year = ""selectyear( DateIn )
elseif( PublicationDate ~= nil and PublicationDate ~= "" ) then
else Year = string.sub(DateIn,-4,-1)
Year = selectyear( PublicationDate )
end
else
Year = ""
end
end
local classname = "citation"
"https://tamilar.wiki/w/Module:Citation/CS1" இலிருந்து மீள்விக்கப்பட்டது