Template talk:Calendar

Broken if not current month?
So first of all, this is like the most insane template I've ever seen. The amount of wiki logic that goes into it is just crazy, and I'm not even going to pretend like I understand all of it. It's really impressive! However, I can't seem to get it working when I want to generate a calendar for a different month. The shaded/unshaded cells seem to be off, perhaps hardcoded for only August 2015.

Any ideas why this could be happening, sunmarsh? -- Ja ke  18:31, August 16, 2015 (EDT)


 * Thanks! ^^; The basic template isn't too complicated, it's when I started to add the shading for previous months and the custom text that things got crazy. From the way it's displaying I can see there are several places in the template that need to be adjusted. I'll see what I can do... Sunmarshsignature.png  ( talk )  18:57, August 16, 2015 (EDT)


 * Don't have time to fix all of this now, but I figured out what the problems are and am basically jotting them down here for later.
 * Nested #ifeq statements should assign previous month dates in descending order.
 * Template needs to check whether cell should be shaded light before shading dark.
 * Wiki logic seems to generate day names for dates a month doesn't necessarily have. (e.g. if September had 31 days in 2015 it would fall on a Thursday). I need to have the template check the amount of days in the current month before entering a date for the possible last day of the month (dates 28-31). Sunmarshsignature.png  ( talk )  19:26, August 16, 2015 (EDT)
 * Just wanted to say: this has got to be one of the coolest and most impressive templates I've seen. You never cease to amaze. ~Super Hamster  Talk 21:41, August 16, 2015 (EDT)
 * Jeezus, SuperHamster and Jake, you guys are right. :D 22:34, August 16, 2015 (EDT)
 * It's so complicated that it actually broke the diff. I've never seen that happen before. -- Ja ke  22:47, August 16, 2015 (EDT)


 * Just a little update on these issues: I've corrected all of the problems with the wrong dates being displayed, however there are still issues with shading in months that have less than 31 days. I also realized while I was fixing these issues that the template will generate an extra week for February if the month begins on Sunday and it is not a leap year. I've generated the code to fix this, but will wait until I've fixed other issues first before applying it, as it requires I reformat some existing code. Hopefully I'll have everything finished tomorrow. Sunmarshsignature.png  ( talk )  22:53, August 18, 2015 (EDT)