Modul:Jahrestag: Unterschied zwischen den Versionen

keine Bearbeitungszusammenfassung
Keine Bearbeitungszusammenfassung
Keine Bearbeitungszusammenfassung
Zeile 27: Zeile 27:
Woche(8, month)..
Woche(8, month)..
Woche(15, month)..
Woche(15, month)..
Woche(22, month)
Woche(22, month)..
Woche(29, month)
if contains({'April', 'Juni', 'September', 'November'}, month) then
md=30
elseif month == 'Februar' then
md=29
else
md=31
end
t = t..'<tr>'
for i=29, md do
    t=t..'<td align="right">'..i..'</td>'
end
t = t..'</tr>'
t = t..'</table>'..month..tostring(md)
t = t..'</table>'..month..tostring(md)
Zeile 48: Zeile 35:


function Woche(d, month)
function Woche(d, month)
a=6
if d == 29 then
if contains({'April', 'Juni', 'September', 'November'}, month) then
a=1
elseif month == 'Februar' then
a=0
else
a=2
end
end
t = '<tr>'
t = '<tr>'
for i=d, d+6 do
for i=d, d+a do
     t=t..'<td align="right">[['..i..'. '..month..'</td>'
     t=t..'<td align="right">[['..i..'. '..month..']]</td>'
end
end
t = t..'</tr>'
t = t..'</tr>'