80 Commits

Author SHA1 Message Date
defacer
685416485b This is now automatically done, no need to do it twice. 2005-02-08 00:12:11 +00:00
defacer
da71112bed Refining the way that blocks work: now you don't have to know anything
about what editing the blocks adds to your URL. blocklib will take care
of that internally.
2005-02-01 06:24:28 +00:00
defacer
7542a4e574 Dropping the use of MOODLE_PAGE_COURSE <gasp>!
The new constant is PAGE_COURSE_VIEW, and it's more streamlined with the
new CSS-related ids for 1.5. There are great possibilities for the future
here, so we 're getting ready.

On the other hand, this has to be the ugliest hack I 've ever inflicted
on any program (look at pagelib.php). Thankfully it will only stay for just
a little while.
2005-01-31 02:18:15 +00:00
defacer
2335781f1c Fixing incorrect use of optional_param. 2005-01-28 00:02:33 +00:00
urs_hunkler
ee4dc51eec changed the name of the special course div to "course-contend" 2005-01-25 15:54:00 +00:00
martinlanghoff
e069b3e2fe Merged from MOODLE_14_STABLE - Closing SC#66 - more 2005-01-22 09:06:51 +00:00
urs_hunkler
daa27ce409 _ added the div framework 2005-01-18 11:08:58 +00:00
defacer
9b12850043 Fix for bug 2241:
I hope this time I got everything changed to the new Page interface! I 'm
really sorry for messing up and breaking new installations... :(

Also moved the only two functions of the API outside the page_base class.
2004-11-29 04:19:05 +00:00
defacer
db019d9358 Ummm... more changes due to the renaming. 2004-11-25 17:35:25 +00:00
defacer
f032aa7a5f MAJOR CHANGES:
--------------

Brand-new pagelib.php at your disposal! It slices, it dices, it makes your coffee.
It still doesn't understand women... Read the comments in pagelib.php for a first
impression. Feedback highly encouraged!

Blocks code has undergone significant changes to work with Pages. Flexibility is its
middle name, since I think (without having tried it) that adding e.g. a third
placeholder for "center" blocks in courses, with full support for moving around etc,
will now take about 15 lines of new or edited code. If you are not impressed yet, I
suggest watching a documentary on solar physics. :P

MINOR CHANGES:
--------------

Added instance_allow_config() in the blocks class hierarchy to supplement per-instance
configuration options. You can override it to return true and thus get configuration
amenities without allowing multiple instances.

Minor polishing to comments and documentation (whatever caught my eye was game).

Tightened up some code here and there by utilizing all the new features.

BUGFIXES:
---------

A bug in restore_execute.html caused hidden blocks to not be restored at all.
2004-11-08 19:36:07 +00:00
defacer
9b4b78fd6a Da monster-commit of blocks version 2!
Code based on the work of Daryl Hawes for the blog module. Thanks, Daryl!

Please test the hell out of it as it's sure to have issues that need to be
ironed out.
2004-10-19 21:04:28 +00:00
stronk7
5b224948aa course/view.php is using sesskey
(changes in blocks done, please check them)

Merged from MOODLE_14_STABLE
2004-10-09 20:16:05 +00:00
moodler
83f3c62dbe Fixed my recently introduced bug with the redirect bug 2000 2004-09-26 02:42:54 +00:00
moodler
4ebae17119 Merged earlier redirecftion for site course 2004-09-23 17:02:02 +00:00
gustav_delius
24f2b65a4d towards XHTML compliance 2004-09-12 12:21:27 +00:00
defacer
2b0d60ec78 Fix for bug 1662:
Changed the way applicable formats for blocks are handled. The changes are
short codewise, but to grasp all the implications read the forum discussion
at the relevant URL.
2004-08-22 16:54:48 +00:00
moodler
093a4a2437 Fixed link of user name in footer of course page 2004-08-02 19:09:54 +00:00
defacer
08cebf196e Fix all requires() to use absolute paths (Sun boxes have problems with relative
paths, it seems). Also, login is required to view the calendar of any course
other than the site.
2004-06-02 08:13:26 +00:00
moodler
af62781bca FIxed defaulting $SESSION->cal_show_user 2004-05-25 06:35:49 +00:00
defacer
0784eb7ef1 Now we can get a list of the blocks being on display in the course page.
Could be used by one block to detect the existence of another, for example.
2004-05-21 11:06:49 +00:00
defacer
82b181f265 Eloy is probably right, the preferred width calculation should be cached. 2004-04-20 07:32:57 +00:00
stronk7
1eb25080df Detected a display bug when looking for possible causes of
bug 1248. Widhts were only calculated in teacher mode and
they were down to 100px in student mode!!
Perhaps we could make some session caching to avoid some
calculations every time the course is displayed. Seems to
work fine now.
Anyway, if I compare the right column width
in my server (with blocks running) against moodle.org (without
blocks), it seems that the right column is narrower in my test server...
2004-04-19 19:24:42 +00:00
stronk7
0f3fe4b6ad First Official realease of the "Blocks System".
Integrated with Moodle:
    - Install automatically.
    - Update course->blockinfo for each course at installation time.
    - Modified course creation to insert into blockinfo field.
    - Modified restore to insert into blockinfo field.
    - Admin options (hide, show, delete, config) from admin page.
    - Lang strings inserted (en only).
    - Database support to mysql and postgresql (not tested!!).
Moodle, backup and block versions updated to 2004041800.
Tested with mysql: Install fresh and upgrade from previous.
section_activities block renamed to social_activities and created
its own lang file to support name "Social Activities". This can
be changed at any time.

TODO:
=====
Support it really in backup/restore.
????

Enjoy!! Ciao :-)
2004-04-18 23:20:53 +00:00
moodler
196ca3fe59 Fixed a bad bug where the Recent News block wasn't obeying Groups properly. 2004-04-12 09:57:14 +00:00
moodler
0d250ac10e Adding calendars by default --- later we need a course option to control
visibility
2004-03-29 15:33:26 +00:00
moodler
c7609872ca May avoid a cookie issue 2004-01-14 03:47:40 +00:00
moodler
6049fb78f2 Modification of the course format plugin structures so that it
fits in with other plugin formats in Moodle.
2003-12-21 04:52:25 +00:00
moodler
8b68eb7ebc I didn't like it as much as I thought. :-) 2003-11-06 09:11:35 +00:00
moodler
43acb21fff Putting link to course listing on the course front page.
If anyone doesn't like this please say so!!
2003-11-06 09:10:01 +00:00
moodler
6bf0078f07 Removed focus from course page - see Bug 825 2003-10-09 12:42:47 +00:00
moodler
c9f6251ea8 Two things are in this checkin:
1) Support for the new "label" module has been added.  It's unfortunate
   about having to make these exceptions but this was the overall cleanest
   way I could think of.

2) All local calculation of pixpath and modpixpath has been removed and
   replaced with a single calculation which is done in setup.php and
   stored in $CFG->pixpath and #CFG->modpixpath.  All graphics should
   use these variables so that themes can easily override them.
2003-09-14 12:25:16 +00:00
moodler
db34bb5992 After rebuilding cache - get the course record again 2003-08-22 16:20:35 +00:00
moodler
56e34ee405 Fixed bug when moving sections with apostrophes in the summary (bug 641) 2003-08-21 15:06:32 +00:00
moodler
73047f2f76 OK, this is a new scheme to allow some teachers to edit and others to not
that is much better than the proposal to change the role of course creators.

There is a new field in user_teachers called "editall", which is
ON BY DEFAULT, and allows teachers to edit courses.  It can be modified
on the teacher editing screen (formerly assign teachers).

The value is cached in the session.

To test for it, there is a new function isteacheredit($course->id)
which works much like isteacher did.

I'm going through now and applying this new function wherever
it is needed.
2003-08-16 05:19:24 +00:00
moodler
48d72fa7c9 *** empty log message *** 2003-08-16 02:45:44 +00:00
moodler
5195536408 Force rebuild of course cache - just in case! 2003-08-14 10:32:51 +00:00
moodler
d0e922a9b2 Full path for some silly Windows machines 2003-06-14 13:04:58 +00:00
moodler
d5945ef02c Fixed path 2003-06-14 12:45:09 +00:00
moodler
7142bc1bbd Check existence of course format 2003-06-13 16:13:51 +00:00
moodler
deca24d5f4 Moving course formats into subdirectory.
This is the first step towards more pluggable course formats that can
be just dropped in to the system.
2003-06-13 08:41:57 +00:00
moodler
12905134ab Sections can now be moved up and down 2003-06-10 15:27:09 +00:00
moodler
783da26290 A bit of an audit and a clean up of require_login to add consistency.
No major problems found, just some code tidy-up
2003-05-24 07:29:17 +00:00
moodler
73fafc3886 Bad bug fixed. Non-teachers could hide/show whole sections. 2003-05-24 06:59:36 +00:00
moodler
dfec7b013f Some clean ups - various things to do with Topics view 2003-05-04 09:43:03 +00:00
moodler
7d99d6959e New feature: hide/show topics! 2003-05-04 07:59:46 +00:00
moodler
dc0dc7d5dd Tidying up the way pix images are used.
It's now also possible to override the standard pix with a set of new ones
in a theme.
2003-04-28 04:32:55 +00:00
moodler
b328523cc1 Style for "You are logged in as xxx" and the link to the course home page. 2003-04-25 09:23:08 +00:00
moodler
a5c411d4c2 Smaller font 2003-04-25 09:01:01 +00:00
moodler
a282d0ffda Adding user's name at the top of the course page.
Just experimenting with it there for a while ... feedback welcome
2003-04-25 06:40:30 +00:00
moodler
7a361c8b55 Removed save_session() - no longer needed. 2003-02-27 02:46:37 +00:00