adding a small monthly calendar

adding a small monthly calendar

by Deleted user -
Number of replies: 13

I want to include a small calendar class ("calendar.php") to the course/view.php page so it appears in the right border, just above 'Latest News'. Would anyone know where in the PHP code I would include the code below?

<?php
include("calendar.php");

// Construct a calendar to show the current month
$cal = new Calendar;
echo $cal->getCurrentMonthView();
?>

Cheers.

Average of ratings: -
In reply to Deleted user

Re: adding a small monthly calendar

by Martin Dougiamas -
Picture of Core developers Picture of Documentation writers Picture of Moodle HQ Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers
That would be course/weeks.php and course/topics.php, towards the bottom. smile
In reply to Deleted user

Re: adding a small monthly calendar

by Tom Murdock -
Tokyo, where do I find the calendar.php file that you are using? I like the idea.

Thanks,
Tom
In reply to Tom Murdock

Re: adding a small monthly calendar

by Jacob Romeyn -

If you look at my site:

http://fortlangley.net/moodle/

You will see a small Calendar which is available from "Codewalker"

It is very easy to use , has an admin in the lefthand corner.  You can add as many users to the admin you like

 The download page for codewalker is here:

http://calendar.codewalkers.com/

 

In reply to Jacob Romeyn

Re: adding a small monthly calendar

by Juan Martinez -

Hi Jacob,

If doesnt bother you i would like want can i do for add a calendar on my moodle. Thanks.

In reply to Tom Murdock

Re: adding a small monthly calendar

by Deleted user -
The calendar I added was a tiny one that can easily fit in the border. It is at: http://calendar.esscripts.com/download.php It seems work ok for me.
In reply to Deleted user

Re: adding a small monthly calendar

by Loren Winfrey -
I have installed this in my topics and weeks, it works nicely.

Designatecc.com click on using site...

If you need instruction let me know. I have it working in topic and weekly formats with no on or off switch.

Loren
In reply to Loren Winfrey

Re: adding a small monthly calendar

by Marcel Berteler -
I checked out he site, but can't realy find a calendar. Am I just not looking in the right place or did you remove it again?

I logged in as a guest and went to 'using this site'
In reply to Marcel Berteler

Re: adding a small monthly calendar

by Loren Winfrey -
Sorry for that, I updated last week and I knew I missed something but wasn't sure what. I have updated the page. the code below is what I used to insert the calendar.


// Print calendar

print_side_block_start( "Calendar", 210,"");
echo "";
include("../calendar/escalendar.php");
echo "";
print_side_block_end();

Locate this line of text " /// Print all the news items.", in the topics.php and weeks.php and paste the above code before it. This will give the box with title.

Then the calendar is from: http://calendar.esscripts.com

It is configurable but still is not clickable as far as moodle goes. But it gives the dislpay which is waht my students needed. If you have more questions feel free to ask...

Loren
In reply to Loren Winfrey

Re: adding a small monthly calendar

by Ger Tielemans -

I like this small calendar that fits in the current Moodle style.

question 1: Will a calendar with this look and feel become part of the Moodle core and also become part of the translations?

 

At our institute groups of students have to visit several Moodle courses. Therefor we will use hyperlinks in webCalendar to sent students on the right our and day to the right Moodles.
 http://webcalendar.sourceforge.net/  

But how can a student go back from a Moodle to webCalendar?

question 2:
Can I give this small calendar a clickable hyperlink to go back to webCalender?
This should be in the style of the other hyperlinks, for example the Title of the Calender should get underlined during hoover over and activate the link if a student does a left-mouse-click?   

In reply to Loren Winfrey

Re: adding a small monthly calendar

by Dan Eliot -
This was a great post, and exactly what I was looking for. Thanks smile

One small suggestion that might help some people (like me). The way you have this set up, it will only use the default calendar configuration. If you would like to use one of the other calendar configurations, the include needs to be changed somewhat to:

include("http://www.yourdomain.com/moodle_dir/calendar/escalendar.php?uc=4");

A different attempt to use a config argument:

include("../calendar/escalendar.php?uc=4");

does not work because the include statement looks for a file named "escalendar.php?uc=4" which doesn't exist.

By making the include() a URL, you can then send arguments to the script, such as the "uc=4" (use configuration four) argument. My big reason for this was so that I could make the date background color the same as the Moodle theme I was using smile

The attached graphic shows this in context.

Moodle rocks...

Dan
Attachment calendar_in_moodle.gif
In reply to Dan Eliot

Re: adding a small monthly calendar

by Juan Martinez -
Dan what can i do to add a calendar on my moodle because a dont load a few one but i have this error this three error what can i do if you got the answer. What i do if download this file and add it on  moodle/mod only; i have to do something else.Thanks

Module 'ESCal45' is not readable - check permissions

Module 'WebCalendar-0.9.42' is not readable - check permissions

Module 'webwork' is not readable - check permissions

In reply to Loren Winfrey

Re: adding a small monthly calendar

by Juan Martinez -

Hi Loren,

How could i add this calendar on my moodle, please let me know.