Page 1 of 1

Show calendar in one row

PostPosted: Tue Aug 12, 2008 2:53 am
by ikaros
Hi,
I would like to show one month in one row i.e. from 1-31 day of the mont in one line/row. Each month in new line/row. Can you please help me with changes?

Regards

Re: Show calendar in one row

PostPosted: Tue Aug 12, 2008 10:22 am
by chris
Hi there,

In the main php file (index.php) in the source code) look for the line:
Code: Select all
if (($j % 3) == 0)$cal_months.="</tr><tr>";

and simply replace with this:
Code: Select all
$cal_months.="</tr><tr>";

That will force a new line after every calendar is drawn.

If you want all the the actual days of each month in a single row, open the file "includes/functions.inc.php" and within the function draw_cal() remove all the lines that make any referenece to a new table row eg:
Code: Select all
if($week_day == 0){
   $the_cal .= "</tr><tr>";
   }

I hope that helps :)

Chris

Re: Show calendar in one row

PostPosted: Tue Aug 12, 2008 10:56 am
by ikaros
Thanks, now it works fine.

Another thing. Now the names of the days are shown only for first seven days. How to show names of the days for all 31 days. Mon-Sun... from 1-31 days.
And Can I change the color of the label for sunday in red?

Thanks

Re: Show calendar in one row

PostPosted: Wed Mar 16, 2011 7:00 pm
by RealIntel
Hi Chris,

Are these changes correct for the current version. I did not find the code

if (($j % 3) == 0)$cal_months.="</tr><tr>";

in the index.php file as suggested

I also only found one reference to....

if($week_day == 0){
$the_cal .= "</tr><tr>";
}

But no effect deleting.....

and can you provide guidance for....

Another thing. Now the names of the days are shown only for first seven days. How to show names of the days for all 31 days. Mon-Sun... from 1-31 days.
And Can I change the color of the label for sunday in red?

Re: Show calendar in one row

PostPosted: Wed Mar 16, 2011 7:45 pm
by chris
Hi,
No, this is a very old thread from 2008 for version 2 of the calendar which is no longer supported.

Chris