Module:Authority control: Difference between revisions

m
→‎top: Fixing name
No edit summary
m (→‎top: Fixing name)
Line 13: Line 13:
local catName = ''
local catName = ''
if namespace == 0 then
if namespace == 0 then
catName = 'Wikipedia articles with '..id..' identifiers'
catName = 'Bharatpedia articles with '..id..' identifiers'
elseif namespace == 2 and not title.isSubpage then
elseif namespace == 2 and not title.isSubpage then
catName = 'User pages with '..id..' identifiers'
catName = 'User pages with '..id..' identifiers'
Line 741: Line 741:
end
end


local catName = 'Wikipedia articles with faulty '..(specialCat or id)..' identifiers'
local catName = 'Bharatpedia articles with faulty '..(specialCat or id)..' identifiers'
return '* <span class="error">The '..id..' id '..rawValue..' is not valid.</span>[[Category:'..catName..']]'..p.redCatLink(catName)..'\n'
return '* <span class="error">The '..id..' id '..rawValue..' is not valid.</span>[[Category:'..catName..']]'..p.redCatLink(catName)..'\n'
end
end
Line 766: Line 766:
local wpl = frame:expandTemplate{ title = 'Wikidata property link', args = args }
local wpl = frame:expandTemplate{ title = 'Wikidata property link', args = args }
--cats
--cats
local articleCat = 'Wikipedia articles with '..category..' identifiers'
local articleCat = 'Bharatpedia articles with '..category..' identifiers'
local userCat =    'User pages with '..category..' identifiers'
local userCat =    'User pages with '..category..' identifiers'
local miscCat =    'Miscellaneous pages with '..category..' identifiers'
local miscCat =    'Miscellaneous pages with '..category..' identifiers'
local faultyCat =  'Wikipedia articles with faulty '..category..' identifiers'
local faultyCat =  'Bharatpedia articles with faulty '..category..' identifiers'
--counts
--counts
local articleCount = lang:formatNum( mw.site.stats.pagesInCategory(articleCat, 'pages') )
local articleCount = lang:formatNum( mw.site.stats.pagesInCategory(articleCat, 'pages') )
Line 1,021: Line 1,021:
outString = outString .. auxCats
outString = outString .. auxCats
if namespace ~= 0 then
if namespace ~= 0 then
outString = mw.ustring.gsub(outString, '(%[%[)(Category:Wikipedia articles)', '%1:%2') --by definition
outString = mw.ustring.gsub(outString, '(%[%[)(Category:Bharatpedia articles)', '%1:%2') --by definition
end
end
end
end