1 (edited by Smorg 2025-03-19 19:37:36)

Topic: Adding the name of the subcatergory to the event title

I have found WHERE to add this, but not sure what variable to use.

In context, I have too many subcategories to be able to use colours to distinguish between them, as the calendar is on display in the room.

Supplementary, where are drop downs for categories being built? I want to be able to hide a category on a particular day.

Thanks

Re: Adding the name of the subcatergory to the event title

I have found the same variable is used when hovering over the event.  The div id is htmlPop if this helps you

Re: Adding the name of the subcatergory to the event title

Hi Smorg,
To add the subcategory to the evnet title in month view can be achieved as follows (for LuxCal 5.3.3).:
The subcategory name for an event is held in the variable $evt['snm'].
So edit the file "pages/month.php" and add just below line 26 . . . .

$snm = $evt['snm'] ? " - {$evt['snm']}" : '';

and change line 28 from . . . .

echo "<div {$onClick}{$popAttr} title=\"{$title}\">{$chBox}{$event}</div>\n";

to . . . .

echo "<div {$onClick}{$popAttr} title=\"{$title}\">{$chBox}{$event}$snm</div>\n";

In other words add "$snm" after "{$event}".

The category /subcategory drop-down menus for the Add / Edit event window are produced in the "pages/eventform1.php" script, functions catMenu (line 24) and scatMenu (line 43) respectively.

Roel