Modul:Stadtwikis: Unterschied zwischen den Versionen

keine Bearbeitungszusammenfassung
Keine Bearbeitungszusammenfassung
Keine Bearbeitungszusammenfassung
Zeile 4: Zeile 4:
function p.Versuch(frame)
function p.Versuch(frame)
t = getAPIdata("https://www.fuerthwiki.de/wiki/api.php?action=query&meta=siteinfo&siprop=statistics&format=json")
t = getAPIdata("https://www.fuerthwiki.de/wiki/api.php?action=query&meta=siteinfo&siprop=statistics&format=json")
x='<table><tr><th>Artikel</th><th>Bilder</th>'
x='<table><tr>'..
x=x..tabelizeData(t)
'<th>Artikel</th>'..
x=x..'</table>'
'<th>Bilder</th>'..
'<th>Bearbeitungen</th>'..
'<th>Benutzer</th>'..
'<th>aktive Benutzer</th>'..
'<th>Adminis</th>'..
tabelizeData(t)..
'</table>'
return x
return x
end
end


function tabelizeData(t)
function tabelizeData(t)
h='<tr><td>'..t['articles']..'</td>'
h='<tr>'..
h=h..'<td>'..t['images']..'</td></tr>'
'<td>'..t['articles']..'</td>'..
'<td>'..t['images']..'</td>'..
'<td>'..t['edits']..'</td>'..
'<td>'..t['users']..'</td>'..
'<td>'..t['activeusers']..'</td>'..
'<td>'..t['admins']..'</td>'..
'</tr>'
return h
return h
end
end