Welcome Guest, Not a member yet? Register   Sign In
Calendar class click event
#1

[eluser]reyntjensw[/eluser]
I'm working with the calendar class and I've managed to add events in this calendar.
Now I'm wondering if there is a possibility to add a link to each event in this calendar so I can redirect the user to and edit page.

Wouter
#2

[eluser]theprodigy[/eluser]
Take a look at this Netuts tutorial.

He goes through explaining the calendar template. You should be able to alter the template to add the link that you want. I don't use the calendar class that much, but I'm sure it shouldn't be that hard.

Another option instead of changing the template is to change the contents of the day array you pass to the generate function.

Instead of:
Code:
$content = array(
    15 => 'Event 1',
    28 => 'Event 2'
);

See if this will work:
Code:
$content = array(
    15 => '<a href="path/for/Event_1">Event 1</a>',
    28 => '<a href="path/for/Event_2">Event 2</a>'
);

Like I said, I don't use it, so I don't know if these options will work, but it's worth a try.




Theme © iAndrew 2016 - Forum software by © MyBB