It is, indeed, as you say - "The Final Solution". I read in awe...

I'm pleased at least that I was on the right lines with  my $row = int( $calnum / 3 );. Unfortunately I had meant to show you the lines:

# Populate container table for my $calnum ( 0 .. $#cals ) { my $row = int($calnum/4); $t->cell( $row, $calnum )->push_content( $cals[$calnum] ); }
but I was in too much of a hurry and pasted the wrong thing:(
I see belatedly that this couldn't have worked because the column numbers are only ever 1 to 3 whereas $calnum is constantly increasing. I have looked in Programming Perl and discovered the modulus operand, but the explanation is rather too opaque for me to understand. Could you explain how it achieves its goal in this case?

Thanks once again for this - I shall not only enjoy - I am thrilled to use it and only hope that one day I might aspire to such things myself.


In reply to Re: Final Solution for Generating a container table in HTML::CalendarMonth? by jonnyfolk
in thread Generating a container table in HTML::CalendarMonth by jonnyfolk

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.