Compare commits

..

736 Commits

Author SHA1 Message Date
moodler 8a6cafc806 Release of 1.0.7 2002-12-10 03:58:07 +00:00
moodler d34189e123 Added styles for forum posts 2002-12-10 02:48:05 +00:00
mits c6f0c3a455 polished 2002-12-09 21:06:27 +00:00
mits 8e664e00b9 Polished 2002-12-09 20:50:44 +00:00
moodler c6d09f2157 More information 2002-12-09 17:27:21 +00:00
moodler 4ba1e2d42a Increment 2002-12-09 17:08:56 +00:00
moodler bf1969570e Fixed blue a little 2002-12-09 16:21:02 +00:00
moodler 8120317e2e Changes for new styles and scheme 2002-12-09 16:10:57 +00:00
moodler e545445874 More fixes for course formats 2002-12-09 14:07:52 +00:00
moodler da00d31744 Latest Japanese files from Mits. This is now a COMPLETE TRANSLATION!
Well done, Mits.   That's LOTS of work.
2002-12-09 13:53:41 +00:00
moodler 2338465770 Tweak to etxt in box 2002-12-09 13:48:31 +00:00
moodler 920bb7ab2f Fix typo 2002-12-09 13:45:44 +00:00
moodler 1d43ffdeab Font size tweaks 2002-12-09 13:40:18 +00:00
moodler 7541bc3e87 More styles 2002-12-09 13:36:55 +00:00
moodler 21ba1d796b testing wrong thing 2002-12-09 12:12:42 +00:00
moodler 469e5eb18e More style and layout tweaking 2002-12-09 12:09:33 +00:00
moodler 4499b2e273 Slight alteration of colouring on printed posts 2002-12-09 10:49:44 +00:00
moodler 69d1973c07 New string readytosend 2002-12-09 10:48:59 +00:00
moodler 42fddf0237 Finish off topics display 2002-12-09 09:03:15 +00:00
moodler fb23e3cbb9 Slight changes 2002-12-09 08:53:49 +00:00
moodler 9307692fdf Add a javascript confirmation when submitting a quiz attempt 2002-12-09 08:20:19 +00:00
moodler 776dc2709f Allow print_all_courses to have width 2002-12-09 07:52:47 +00:00
moodler d9fd5e8b86 Allow course listing to have specified width 2002-12-09 07:51:31 +00:00
moodler 041b1712c6 Slightly adjust column width 2002-12-09 07:48:12 +00:00
moodler b27f9a32bc Slight changes 2002-12-09 07:45:45 +00:00
moodler 24a34da28c Updated version 2002-12-09 07:36:48 +00:00
moodler 5e367a2d56 Various little tweaks to improve the display of course home
pages and front page ... still have some work to do though
2002-12-09 07:35:40 +00:00
moodler 7a4c13797a Default with showrecent ON 2002-12-09 06:35:14 +00:00
moodler 64a92277da Fixed US spelling 2002-12-09 03:25:48 +00:00
moodler 1e6700a749 Restored "locale" string 2002-12-09 03:10:44 +00:00
moodler 651ba4e63c Latest changes in French, from Sebastien Nam?che 2002-12-09 03:00:54 +00:00
moodler 4be38f8bb2 CHanges from Antonio Navarro 2002-12-09 02:39:19 +00:00
moodler 2e4b204b26 Changes to make makeClassFromFile() in makeclass.php work better 2002-12-09 02:12:37 +00:00
moodler 1ed2b03af3 Fixed some names 2002-12-08 17:32:11 +00:00
moodler 339bb5599f New code to use locale information from language packs if necessary 2002-12-08 17:26:21 +00:00
moodler a8b7b66158 Use language string for "changes saved" 2002-12-08 17:21:10 +00:00
moodler 2893d91e46 Fixed name 2002-12-08 17:16:58 +00:00
moodler df0594edee Added locale codes to all languages 2002-12-08 17:01:13 +00:00
moodler 517f323637 US flavor of English to keep the yanks happy. ;-) 2002-12-08 16:49:49 +00:00
moodler 520283b4e4 Added Mitsuhiro's credit for Japanese 2002-12-08 11:28:32 +00:00
moodler 15a2a4e555 Updates for 1.0.7 and better-looking throughout 2002-12-08 03:45:03 +00:00
moodler 261be01672 More changes from Mits. 2002-12-07 16:19:58 +00:00
moodler 6ab29e19a4 Going back to simpler version numbers! 2002-12-07 08:53:07 +00:00
moodler 86400f05f5 Small changes to help display of Japanese and on Netscape 2002-12-07 08:44:21 +00:00
moodler 467aaec630 Small changes to tables to make them display better with Japanese 2002-12-07 08:39:24 +00:00
moodler a8a71844e4 If the database doesn't work then just die before anything else 2002-12-07 07:27:58 +00:00
moodler 657423c8f3 get rid of short_open_tags 2002-12-07 07:27:18 +00:00
moodler 95ea4a41ad Some info about forcetables 2002-12-07 07:19:28 +00:00
moodler 2348daf12c Updated the dox 2002-12-07 04:37:21 +00:00
moodler ec2e229a0f General purpose function to produce a class based on a library
of simple functions.  Can be used to provide a class interface
to Moodle functions.

Thanks to Greg Barnett!
2002-12-07 04:31:23 +00:00
moodler d72788c346 Added php mime type 2002-12-07 04:24:22 +00:00
moodler 81ef6a5ee5 Removed the "zero" value altogether 2002-12-07 04:20:35 +00:00
moodler ff4f23fdcc Better checking of existing value, in case it's not in the list 2002-12-07 04:00:05 +00:00
moodler 0fa2146388 More changes from Mits! 2002-12-06 12:22:59 +00:00
moodler 3e8ff7019f Fixed up CVS Id tag 2002-12-06 11:36:20 +00:00
moodler 2ccb36740b Wrapper file to make moodlelib.php functions accessible as a class
called moodlelib.  Based on idea from Greg Barnett:
http://moodle.com/mod/forum/discuss.php?d=356
2002-12-06 11:23:42 +00:00
moodler a7ce613296 First version of Japanese translation by Mitsuhiro Yoshida !
Still missing quiz.php, survey.php, auth.php and the help files

Helpers wanted!
2002-12-05 13:50:01 +00:00
moodler 035cdbff1a Improved removal of leading zeroes, but with some efficiency lost 2002-12-02 01:35:18 +00:00
moodler bea7a51e3c Slight change to get rid of leading zeroes in dates 2002-12-02 01:13:14 +00:00
moodler 8ea300947d These includes are actually required 2002-12-02 01:12:06 +00:00
moodler 666122b94b Upgraded ADOdb to 2.50 because it fixes some bugs with PHP 4.3.0 2002-11-30 13:23:39 +00:00
moodler 8da0e0e031 IMS/SCORM 2002-11-30 12:04:33 +00:00
moodler 3ad6393067 Revised 2002-11-30 12:00:47 +00:00
moodler 17820bd5bd New version of Italian translation - compatible with 1.0.6.3 2002-11-29 15:17:59 +00:00
moodler 39246b72f8 Some colour difference for my courses .... I'm not sure about it ... 2002-11-29 14:22:34 +00:00
moodler 85098089d1 Some improvements to the layout of courses when there are categories
and they are on the front page
2002-11-29 14:17:36 +00:00
moodler 3475d55ee7 Slight fix 2002-11-29 05:12:01 +00:00
moodler c1e735bb28 Added credit for Indonesian - Arfan Hidayat 2002-11-29 05:02:59 +00:00
moodler a08fe5809a Complete new Indonesian translation!
Thanks to Arfan Hidayat, http://www.kursusmaya.com, ivanh@telkom.net!
2002-11-29 04:58:27 +00:00
moodler b419cb6e28 Update version 2002-11-28 14:39:26 +00:00
moodler 3086f3f6cf With external authentication, the change password button on the user
page now does the same thing as the one on the login page.  It takes you
to the specified URL is it exists, and just doesn't appear if there is no URL
2002-11-28 12:31:46 +00:00
moodler 048ccc473a Highlight matches in post subject and discussion name too 2002-11-28 09:10:22 +00:00
moodler 88e729beed Add searching of subjects as well as messages 2002-11-28 09:04:04 +00:00
moodler d391e3b1ee First quick version of help on CVS 2002-11-28 03:05:24 +00:00
moodler 6cc0361107 Fixed heading 2002-11-28 02:53:25 +00:00
moodler c655755d92 Updates 2002-11-28 02:47:50 +00:00
moodler 64efda84b5 Fixes to increase the number of options available to limit assignment
upload size, and also to limit the list based on PHP limits
2002-11-28 02:41:56 +00:00
moodler f42cf95f3c Added missing </BODY> and </HTML> tags 2002-11-27 13:11:02 +00:00
carlesbellver 5c36a37c9f *** empty log message *** 2002-11-26 10:10:04 +00:00
moodler 0581a9f7c8 More info about database user 2002-11-26 03:19:15 +00:00
moodler b275ff65cb Additions and clean ups 2002-11-26 03:07:49 +00:00
moodler 71d552f677 Fix display of grades when there aren't any grades 2002-11-26 02:36:16 +00:00
moodler 83173d563c For the case when there are forums using ratings, but no ratings, and
the teacher is looking at grades, don't try and loop on an empty array
2002-11-26 02:29:54 +00:00
moodler fc05fccb64 Strip slashes from filenames 2002-11-26 02:11:05 +00:00
compuproggy 33651b3d3e *** empty log message *** 2002-11-25 06:45:08 +00:00
moodler 4d35cddd8a More fixes 2002-11-24 15:59:58 +00:00
moodler 2f0c25fc75 More tweaks 2002-11-24 15:44:59 +00:00
moodler 982d256d95 Yet more details 2002-11-24 15:40:07 +00:00
moodler 66fe2bb262 Updated versionm, ready for 1.0.6.4 2002-11-24 15:30:01 +00:00
moodler e746ec3416 More tweaks 2002-11-24 15:22:28 +00:00
moodler d40c314a0a More fixes 2002-11-24 15:20:29 +00:00
moodler 56b21759e5 More details 2002-11-24 15:16:49 +00:00
moodler 9ae472a374 New message about users being automatically unenrolled 2002-11-22 17:28:55 +00:00
moodler 7f1717c61e ALL LANGUAGE EDITORS PLEASE NOTICE THIS CHECKIN
I've changed htmlentities to htmlspecialchars in this file, to fix
bugs with editing multibyte languages (ie Japanese).  Please be
cautious and let me know if this causes any problems when editing
your language (it shouldn't, but I don't want to spoil your day!)
2002-11-22 17:27:56 +00:00
moodler 708964056e Update for kicks 2002-11-22 10:00:50 +00:00
moodler bcd6e7184f Hide password and unenrolment buttons from guest users 2002-11-22 09:59:31 +00:00
moodler 92710226a5 Tidy up some of the dox 2002-11-22 09:38:15 +00:00
moodler 466558e349 Changes to allow admin to control the "forgot password" function
and a bug fix for set_config
2002-11-22 08:43:35 +00:00
compuproggy caa963b03b Suche noch Lernwillige und Tutoren f?r http://www.selaction.de
Auch Mithelfer sind gerne gesehen wie ?bersetzer oder Moderatoren.
2002-11-22 07:39:08 +00:00
compuproggy 0cf3883167 Suche noch Lernwillige und Tutoren f?r http://www.selaction.de 2002-11-22 07:37:26 +00:00
paca70 ef62651f02 Fixed some typos 2002-11-21 18:40:33 +00:00
moodler b335cae1d3 Updated version 2002-11-21 16:59:41 +00:00
moodler cff8ba5a98 Moodle CVS is exactly 1 year old. :-) 2002-11-21 16:58:29 +00:00
moodler c351cf2799 For long courses reduce the text printed on x axis 2002-11-21 16:19:19 +00:00
moodler d751ddcb5d Reduce errorlevel reporting 2002-11-21 16:07:58 +00:00
moodler 372ce3d10c COnverted it to DOS format to make it easier for Windows users 2002-11-21 16:00:18 +00:00
moodler ad40c8a23c Updates 2002-11-21 15:30:53 +00:00
moodler 3b9a79f977 Fixes to allow graphs to be translated 2002-11-21 14:57:10 +00:00
moodler 89b5432563 Allow admin user to always get in, no matter what the authentication method 2002-11-21 12:39:33 +00:00
paca70 fd6a7ee524 New files for translation 2002-11-21 12:17:15 +00:00
moodler 6ae24de0e1 No longer need the getuserinfo parameter 2002-11-21 11:28:46 +00:00
moodler 7c58aee6c7 Added full configuration to LDAP (ie transferrable fields etc) 2002-11-21 11:27:44 +00:00
moodler 7ff671df29 Bug fix for dbtype menu 2002-11-21 11:12:55 +00:00
moodler b3f9585bcb Daily changes 2002-11-21 10:33:24 +00:00
moodler 02accd9c6a Fixed a bug from reusing newsubmission variable 2002-11-21 10:26:54 +00:00
moodler f10ed36d8d Error checking on image writes 2002-11-21 10:23:10 +00:00
moodler b913b369e8 Small bugfix with uploading new user images 2002-11-21 10:17:08 +00:00
paca70 f74dcc5e08 some updates 2002-11-21 08:26:27 +00:00
moodler 009b59336b Updated version (authentication tweaks) 2002-11-21 07:53:35 +00:00
moodler 34daec9b3b Tweaks to authentication system. Database method now allows other
fields to be specified so that things like email, names etc can be
pulled in from external database when new Moodle accounts are created
2002-11-21 07:37:21 +00:00
moodler 780db23080 Slight improvements to file security (scan for more bad characters) 2002-11-21 02:51:50 +00:00
moodler 6e07f68039 Fixed background colours of recent activity and news 2002-11-20 15:24:34 +00:00
moodler 1e77d2035c Update version slightly 2002-11-20 15:17:03 +00:00
moodler d26c7f1740 Forgot a comma 2002-11-20 15:16:03 +00:00
moodler bb90c4e867 Added guestloginbutton as default 2002-11-20 15:04:21 +00:00
moodler 277d2d9f3e Make sure guestloginbutton is set to 1 as a default 2002-11-20 15:03:06 +00:00
moodler 3790f3a151 New string for general form errors 2002-11-20 15:01:59 +00:00
moodler 15e4b2ecd9 User pictures no longer are links on main view page 2002-11-20 14:58:24 +00:00
moodler a406cdec66 Made the user profile a little more robust.
Uploaded images are now saved even if the rest of the form
has errors.

If errors are found in the form then a message is printed up
the top to make it clearer that they need to fix something.
2002-11-20 14:52:32 +00:00
moodler bd4707bf29 Er.. aligned center works better ;-) 2002-11-20 09:41:02 +00:00
moodler 68e1b65291 Fixed alignment on category boxes in some circumstances 2002-11-20 07:18:55 +00:00
moodler b66265fe0b Spacing 2002-11-19 16:16:37 +00:00
moodler bdbf373097 New version before release 2002-11-19 16:15:51 +00:00
moodler 8afe23aa9a New features and fixes 2002-11-19 16:14:47 +00:00
moodler 4ef1e78349 New files (not translated yet) 2002-11-19 15:54:12 +00:00
moodler 3c1cb3178b Checking in new updates from Fabricio 2002-11-19 15:52:25 +00:00
moodler b03b72770b Daily changes 2002-11-19 15:07:40 +00:00
moodler 076b229292 Changed it to DOS format to help Windows users 2002-11-19 14:35:07 +00:00
moodler 62c13a2f3e Changed all references of %e to %d to fix strftime on Windows 2002-11-19 14:27:57 +00:00
moodler 60459ef768 Added Authentication to admin_links 2002-11-19 09:55:54 +00:00
moodler 8297c9a012 More fixes 2002-11-19 09:09:11 +00:00
moodler 2827f134cf Fixed some strings 2002-11-19 09:06:42 +00:00
moodler 35a48c9ae4 A significant new system for authentication configuration that
exposes the wide array of authentication possibilities.

Authentication now has it's own page separate from other variables.

Most of this work was done by Petri Asikainen <paca@sci.fi>, who started
these changes off.

I've done some cleanups and additions which is why I'm checking it in.

It's all working pretty well at the moment but could use some testing.

Thanks, Petri!  :-)
2002-11-19 08:51:33 +00:00
moodler dfe952f2ea Small change to allow the same user (by email) be deleted more than
once.  Also some security in making deleted usernames very hard to guess.
2002-11-18 12:21:27 +00:00
compuproggy e1e499e02c An alle English-Deutsch ?bersetzer, wer hilf mit? -
To all english german translators, who wants to help me?
2002-11-18 07:00:24 +00:00
compuproggy 9127aca8cd *** empty log message *** 2002-11-18 06:57:57 +00:00
moodler 2b8d022c20 Fixed the O's 2002-11-18 01:57:32 +00:00
moodler e3234db924 Added Norwegian 2002-11-18 01:56:09 +00:00
moodler dbd019866f Removed an empty file 2002-11-18 01:42:26 +00:00
moodler c49de76319 Complete Norwegian translation by Joran Sorbo! joran.sorbo@teleweb.no 2002-11-18 01:41:20 +00:00
moodler e1fb2ab5e8 New imap type (imaptls) solved problems with TLS capable servers (eg Courier) 2002-11-17 15:11:35 +00:00
moodler da978ae4c7 Minor formatting 2002-11-17 11:03:59 +00:00
moodler b9b2750adb Added info about $CFG->buggy_referer 2002-11-17 11:00:55 +00:00
moodler 303077fdb5 Updated version for those using CVS etc 2002-11-17 10:46:02 +00:00
moodler 60f18531c8 A default format for format_text() and a workaround embedded
for sites with the buggy referer problem :

  define $CFG->buggy_referer = true in the config.php to activate it
2002-11-17 10:45:34 +00:00
moodler 123d2ebbc5 Now displays instructions for any authentication method 2002-11-17 10:07:01 +00:00
moodler 817c698e8f Slight updates 2002-11-17 09:57:34 +00:00
moodler 704da28e4d Remove { error, and move things around 2002-11-17 02:51:36 +00:00
moodler 23cbf014c0 When someone logs out, cler all sessions and send them to home page 2002-11-16 14:24:49 +00:00
moodler bf09e379a4 Some docs added 2002-11-16 04:26:54 +00:00
moodler 98bc913c2c Slight fixes with defaults etc 2002-11-16 03:56:00 +00:00
moodler df3988ea8b Separated code for IMAP into IMAP, POP3 and NNTP 2002-11-16 03:49:32 +00:00
moodler 3829c7bdd0 Added es_mx from Claudio ... :-) 2002-11-15 16:59:15 +00:00
moodler bb56980c83 Small tidy up of names 2002-11-15 12:49:21 +00:00
moodler d5b94ef46c Nothing missing, just needs testing and debugging 2002-11-15 09:13:31 +00:00
moodler d17bdf2b37 More options and faster (use IPs always) 2002-11-15 08:59:30 +00:00
moodler d1b4e17267 More authentication possibilities 2002-11-15 08:42:40 +00:00
moodler dce48fc85a First version of code to authenticate against external database.
This NOT TESTED yet, and has parameters hardcoded ... it will of
course be using Petri's config interface later when that's ready.
2002-11-15 08:25:24 +00:00
carlesbellver b2649432db *** empty log message *** 2002-11-15 07:21:56 +00:00
moodler 085bd98e7e Add option that allows students to resubmit after being graded 2002-11-15 03:32:30 +00:00
moodler 0431bd7c73 Extend the range of allowable timezones up to 13 hours ... (NZ Daylight savings) 2002-11-15 02:46:48 +00:00
moodler cc94d11b83 Some updates 2002-11-14 13:33:19 +00:00
moodler d483bcd35d Typo in variable 2002-11-14 11:48:01 +00:00
moodler 98c4eae3ac Set the character set of email to be the same as the default language 2002-11-14 11:45:14 +00:00
carlesbellver db5b2eaa17 *** empty log message *** 2002-11-14 07:59:31 +00:00
moodler 661890114b Re-rolling 1.0.6.3 2002-11-14 06:34:15 +00:00
moodler a15803d3d8 Argh ... fix for Netscape fix - was causing problems on other browsers 2002-11-14 06:22:13 +00:00
compuproggy 2f2e3a49a3 *** empty log message *** 2002-11-14 06:01:26 +00:00
moodler 82af8447ed Updated link for Antonio 2002-11-14 04:14:32 +00:00
moodler 5f29b7e9c5 Mention the fix for very large classes 2002-11-14 03:59:44 +00:00
moodler f8ef7d66a2 Getting ready for 1.0.6.3 release today 2002-11-14 03:14:10 +00:00
moodler cfc12f2d97 Changes from Antonio to bring it up to date with 1.0.6.2! 2002-11-14 02:43:01 +00:00
moodler a6fcdf98af Update course cache when creating new standard forums! 2002-11-14 02:33:48 +00:00
moodler 7e72f66016 Catalan translation by Carles Bellver (with the help of Merc? Renau,
Clara Andr?s and Jordi Adell).
2002-11-13 15:23:29 +00:00
moodler 21d7e306b1 Spanish (Spain) provided by Antonio Navarro (based on es_mx) 2002-11-13 13:49:30 +00:00
moodler 4a16445a3a Returning to previous version 2002-11-13 13:30:45 +00:00
moodler 34e46e5787 Small script to force tables to be created even if the database already
contains tables ... useful for sharing with other applications.
2002-11-13 12:09:18 +00:00
moodler fcf8e83671 WHoops bad typo ... made everyone a guest! 2002-11-13 06:26:36 +00:00
moodler 910d1731af Guest language ALWAYS the same as the current site language 2002-11-13 02:11:50 +00:00
moodler 9769da67ab Improvements in appearance for Netscape browsers 2002-11-12 17:20:36 +00:00
moodler 81b635c360 Improvements to formatting on old Netscape browsers 2002-11-12 17:20:04 +00:00
paca70 e0dfdf25f8 More updates 2002-11-12 14:19:24 +00:00
compuproggy 342f96b5a3 *** empty log message *** 2002-11-12 13:28:22 +00:00
compuproggy 54262b876f *** empty log message *** 2002-11-12 13:21:25 +00:00
paca70 05da6502ba added support for list users from ldap. 2002-11-12 12:10:08 +00:00
paca70 0aea12d689 Some updates 2002-11-12 06:00:09 +00:00
moodler ff446576af Small fix just in case numfiles isn't set ... it will still try to display
files if timemodified is set ... workaround for possible bug
2002-11-12 05:05:21 +00:00
moodler c75f5b4348 Small tweak to specify specifically number of files in an update 2002-11-12 04:59:28 +00:00
moodler b68de3e4d9 Updated version number 2002-11-12 04:29:49 +00:00
moodler 13beeacbcd New course option to enable/disable display of "recent activity" 2002-11-12 04:26:16 +00:00
moodler cbb0fee071 For very large classes don't even try to show all the participants 2002-11-12 03:02:51 +00:00
moodler 553064412d Better looking headings with right-to-left languages 2002-11-12 02:19:44 +00:00
compuproggy 469a4e8568 *** empty log message *** 2002-11-11 12:27:58 +00:00
moodler 3b5bf411db Updates 2002-11-11 08:35:09 +00:00
moodler 48e4f8bc3a Missing file 2002-11-11 08:32:31 +00:00
moodler 0aa65a3935 Slight update to release notes for clarity 2002-11-11 08:28:39 +00:00
moodler 3635d82ff3 Updated version for final release of 1.0.6.2 2002-11-11 08:25:41 +00:00
moodler 7304b852cd Slightly more info in error message 2002-11-11 08:25:05 +00:00
moodler 07358d40a4 30 per page 2002-11-11 08:03:54 +00:00
moodler ad81212ec3 Rearranged code so some output is printed before tackling the big table 2002-11-11 07:58:11 +00:00
compuproggy 8f1370c603 *** empty log message *** 2002-11-10 21:48:28 +00:00
moodler 7c0f298426 Update course cache when modules are moved up or down 2002-11-10 14:45:11 +00:00
moodler 76d6be7020 Put a menu on the documentation 2002-11-10 14:05:52 +00:00
moodler e34461f5ea Use #defines for resource types ... just esthetics 2002-11-10 14:03:25 +00:00
moodler cdc27f74a3 Added navmenu for journal edit page 2002-11-10 11:44:58 +00:00
moodler f7e4436690 Fixed front page display of modules 2002-11-10 11:14:06 +00:00
moodler 26d037e63a New info, ready for 1.0.6.2 release 2002-11-10 11:10:19 +00:00
moodler 2ee50b1a5d Added paging now, so this page is now usable with many users 2002-11-10 11:00:57 +00:00
moodler 723974203f New string 2002-11-10 10:40:02 +00:00
moodler 584f0a10ed Starting to speed up this page 2002-11-10 10:19:06 +00:00
moodler 7bee16d404 More sensible varible names 2002-11-10 08:55:39 +00:00
moodler c408b0c49b print_section now uses cached course modinfo to lessen load in database 2002-11-10 08:55:11 +00:00
moodler dfc9ba9bbe Added navmenu in more places 2002-11-10 08:43:44 +00:00
moodler 3e50a13968 Fix to break out of frames 2002-11-10 08:08:23 +00:00
moodler 4359e8f715 Typo in navmenu 2002-11-10 07:59:01 +00:00
moodler f0207959ab Bring back button to home page, update versions etc 2002-11-10 07:57:11 +00:00
moodler b1ae5fb0a8 Added menu stuff to other themes 2002-11-10 07:44:01 +00:00
moodler d897cae419 Changes to enable jumping between activity modules, using a new menu in
the upper-right corner.   Caution: Not well tested at this stage.
2002-11-10 07:37:15 +00:00
moodler 14272cdc38 Latest from Gilberto 2002-11-09 08:35:06 +00:00
moodler 4fdb415494 New version date 2002-11-09 06:52:30 +00:00
moodler f39d5f4576 Use course setting for "student" 2002-11-09 06:29:21 +00:00
moodler b309c289db WHoops typo 2002-11-09 06:24:21 +00:00
moodler f762c448ef FINALLY! Surveys are now translatable! :-) 2002-11-09 06:22:57 +00:00
moodler 8dfc9d0f19 Using LOCALE defines, not strings 2002-11-08 01:33:04 +00:00
moodler cdb56e3dc5 Modified files from Fabricio 2002-11-07 12:05:17 +00:00
moodler f426a62eff Header "login" link now breaks out of possible frame 2002-11-07 11:18:18 +00:00
moodler 8552044d4d Update for course format changes etc 2002-11-07 09:34:51 +00:00
moodler 9a22359743 Fixes to course display, tidy up of some code (could do with more)
and mainly - addition of section 0 display.
2002-11-07 09:30:41 +00:00
compuproggy 8f577101f4 *** empty log message *** 2002-11-07 08:53:53 +00:00
moodler 9fc3aa87b4 Tweaks 2002-11-07 03:01:53 +00:00
moodler 6f3ba7c93d Make a $homepage flag for use in footers 2002-11-06 15:46:12 +00:00
moodler 405ea757e6 Fixed some more missing strings 2002-11-06 09:13:19 +00:00
moodler 941dd21efb Fixes and simplification 2002-11-06 08:54:28 +00:00
moodler 4242a73f37 Bug fix on record counting 2002-11-06 08:44:44 +00:00
moodler aa96df8fef New version and release notes for 1.0.6.1 2002-11-06 08:30:33 +00:00
moodler f9f48383e3 New string 2002-11-06 08:24:54 +00:00
moodler 22710216f2 Add link to module editing ... back to module type list 2002-11-06 08:24:29 +00:00
moodler b7b4287462 Added new type of assignment - offline.
This type of assignment doesn't require anything of the student online,
it just tells them about an assignment and the teacher can provide
feedback and grades.  Useful for offline activities, and also for the
teacher to add manual columns to the grades page
2002-11-06 08:12:06 +00:00
moodler 65ccdd8cc8 When using loginas to be a student, you can now return to being
yourself using a link in the footer.  Improvements to footer display
2002-11-06 07:54:44 +00:00
moodler 7cbfca14c7 Added string for search results 2002-11-06 07:40:56 +00:00
moodler 46217d06b5 Language fixes 2002-11-06 07:40:36 +00:00
moodler 5ebe27e22c Fixed notices a bit 2002-11-05 16:47:30 +00:00
moodler cb909d74ca Fixes to prevent teachers using loginas to enter other courses as that student 2002-11-05 16:38:02 +00:00
moodler 34fdf5b933 Minor wording changes 2002-11-05 07:06:36 +00:00
moodler 3ea810dab0 Added Spanish 2002-11-05 07:04:44 +00:00
compuproggy 4249e34fbf *** empty log message *** 2002-11-05 06:34:57 +00:00
moodler 9f58537a53 Added SMTP authentication for email delivery 2002-11-05 06:06:18 +00:00
moodler 54e90f2d97 Checking in for Holger 2002-11-03 14:35:37 +00:00
moodler 9368247eb6 Simple help about assignment types 2002-11-03 09:34:17 +00:00
moodler 5331c4645b Changes from Fabricio Valadares 2002-11-02 17:34:35 +00:00
moodler 55dace4186 Updates from Claudio 2002-11-01 02:53:50 +00:00
moodler ad6c33dcaa New guest language is same as site 2002-11-01 01:11:46 +00:00
compuproggy 6f4db0e365 *** empty log message *** 2002-10-31 05:52:11 +00:00
paca70 32385d38a1 Initial Finnish translation 2002-10-30 19:20:48 +00:00
moodler b176f8e4cb Updated name of thislanguage 2002-10-30 02:40:46 +00:00
moodler 8b303d1d15 Updated version a little 2002-10-30 02:19:23 +00:00
moodler effdbf913f A very early Arabic translation 2002-10-30 02:09:19 +00:00
moodler b7808b3d97 Spanish translation (Mexican flavour) from Gilberto Rodr?guez et al 2002-10-30 02:00:40 +00:00
moodler ebaf37b55d Checking in CHanges to be part of a 1.0.6 rebuild to include the last
few days of minor changes (documentation etc)
2002-10-29 16:47:16 +00:00
moodler 7209909ec9 On second thoughts, don't apply locale to numbers because it may
affect some calculations.   Just strings and times.
2002-10-29 15:33:09 +00:00
moodler fa0c7d6d91 Use the locale to set everything (eg string conversions, comparisons,
money numbers etc instead of just the time)
2002-10-29 15:25:22 +00:00
moodler 024172be96 Fixed links back to top 2002-10-29 15:02:09 +00:00
moodler 27c82ede5e added documentation 2002-10-29 14:57:12 +00:00
moodler e149249bd2 Improvements to documentation formatting, content etc 2002-10-29 14:48:58 +00:00
moodler 533e975551 Added session.auto_start (off) ... having it turned on will break Moodle
on some versions of PHP
2002-10-29 12:30:31 +00:00
compuproggy 95152d474a *** empty log message *** 2002-10-29 06:24:12 +00:00
moodler 53f2259aa9 Added short_open_tag 2002-10-29 04:04:08 +00:00
moodler a5d34d51cb Removed UPGRADING.txt (replaced by doc/upgrade.html) and updated README.txt
to make it a bit clearer about where all the docs are.
2002-10-29 03:52:10 +00:00
moodler d6cd6ec4f6 New upgrading page (replaces the old UPGRADING.txt) 2002-10-29 03:47:43 +00:00
compuproggy 3129b66906 *** empty log message *** 2002-10-28 13:24:25 +00:00
compuproggy cb87603810 *** empty log message *** 2002-10-28 12:12:16 +00:00
moodler 41f2f344ab Show date in red if assignment date has passed 2002-10-28 02:25:18 +00:00
moodler f59d8272e8 Use translated strings for all upload feedback 2002-10-28 02:24:38 +00:00
moodler 660c20a6ba Added some new strings 2002-10-28 02:24:01 +00:00
moodler 52ab14dd82 Fixed "uploaded assignment" (uploadsuccess) string 2002-10-28 01:30:00 +00:00
compuproggy 519c5a76cd *** empty log message *** 2002-10-27 15:04:30 +00:00
moodler 627de17eda Typo (Survey mentioned twice) 2002-10-27 03:10:10 +00:00
moodler 4a3e5f7e25 Missing a bracket ) 2002-10-26 14:36:01 +00:00
moodler 97f3bedc10 I mean it!! This is 1.0.6!!!! 2002-10-26 06:16:33 +00:00
moodler 3a50203f34 Fixed small bug that was displaying fractions with too many decimal places
(eg 0.9999 instead of just 1)
2002-10-26 06:11:43 +00:00
moodler e386617506 OK, this is 1.0.6 2002-10-26 05:50:09 +00:00
moodler 06a609e91e One more thing - I' moved the RELEASE.html into the other documentation
to make it easier to find later on.
2002-10-26 05:37:31 +00:00
moodler 736458f308 Moving ../RELEASE.html to here 2002-10-26 05:32:26 +00:00
moodler 5946a43ee9 TIME TO CUT THE CORD, GENTLEMEN. THIS IS 1.0.6. 2002-10-26 05:26:06 +00:00
moodler cb62c00ad2 Fixed minor bug after creating default category. 2002-10-26 05:17:53 +00:00
moodler 960a79887b Updated version numbers in preparation for 1.0.6 release 2002-10-26 04:37:56 +00:00
moodler 67f0b4ccb0 Better formatting for the link 2002-10-26 03:37:06 +00:00
moodler a8afb411a0 OK, this should be better ... 2002-10-26 03:33:07 +00:00
moodler c585fa1707 A first try at a new shortening algorithm ... checking in to do some
tests on various servers
2002-10-26 03:21:41 +00:00
moodler 211ee674b3 Changed type of quiz_answers.feedback to TEXT (255 chars was a bit cramped) 2002-10-26 03:13:54 +00:00
moodler 0ee8d9203e Added some commented-out code that MIGHT help people with string slash problems. 2002-10-26 02:31:49 +00:00
moodler 2138dcf29d Added quiz max grade in column title, for reference 2002-10-25 15:34:05 +00:00
moodler 153cc356cb Added TARGET=_blank to links in HTML email ... apparently these links
were causing problems in Hotmail.  Normally I'd say "Good!", but ...  :-)
2002-10-25 15:27:12 +00:00
moodler 86c5e69a36 Remove "news" and "social" forums from learning forums. 2002-10-25 14:46:42 +00:00
moodler 690b1941fc About time 2002-10-25 09:14:16 +00:00
moodler e6874d9ff6 Brand-new news and social forums are now also assigned course modules and
put in section 0 of the course.
2002-10-25 09:10:40 +00:00
moodler 95e143f4cc Ugh type in string module name 2002-10-25 08:54:29 +00:00
moodler 7beb45d8a0 Upgrading all news and social forums (except those in social courses)
so that they are course modules in an (invisible) section, which means
they are now editable and parameters, names etc can be changed.
2002-10-25 08:47:53 +00:00
moodler bd823371c9 Making it clear not to overwrite old files 2002-10-25 08:42:06 +00:00
moodler e11c24bc0e Added translation for Attempt quiz now 2002-10-25 08:15:03 +00:00
moodler 256d0b7b47 Slight change to configlocale ... added examples 2002-10-25 08:01:48 +00:00
moodler 6c506ca744 Disallow people posting in forums where they arent allowed to post! 8-. 2002-10-25 07:22:59 +00:00
moodler 87a2fa0338 Tweaks 2002-10-25 07:17:23 +00:00
moodler f690562f81 Tweaks to mail formats so that unnecessary information (replies, etc)
is not printed.
2002-10-25 06:50:40 +00:00
moodler 3260de6780 Tweaks to forum formatting 2002-10-25 05:58:39 +00:00
compuproggy 4a91f52161 *** empty log message *** 2002-10-25 05:46:33 +00:00
moodler 1ea355a851 Latest updates from Fabricio 2002-10-25 03:20:59 +00:00
moodler ed4ed0939b Weekdays are now calculated using userdate, so that
- they are relative to the user
  - they should take advantage of locales etc
2002-10-25 02:11:58 +00:00
moodler 2be8b28f3d Changes to improve usability when the admin folder has been renamed,
and also a change in checking for the admin user, just in case an
old session is hanging around
2002-10-25 02:02:02 +00:00
moodler 255f2cc06e All the variables were missing! 2002-10-24 13:41:52 +00:00
moodler 4313922f65 Fix for category box display on IE 2002-10-24 12:49:53 +00:00
moodler e7b7951c0a The BR in print_post was to fix the case when embedded images are used.
However it added too much space.  I'll find a way to fix the embedded
images problem later, during the styles changeover, as it's pretty
rare.
2002-10-24 07:09:29 +00:00
moodler 23877f9407 never upgraded choice tables to six choices! 2002-10-24 03:43:37 +00:00
moodler 6673b085a9 Updated with some new features 2002-10-24 03:11:57 +00:00
moodler 3d27c2c201 Added a new debugging command so that I can see the config variables 2002-10-24 02:42:26 +00:00
moodler f6b502d246 more readable 2002-10-23 14:38:24 +00:00
moodler eb8eb6abc5 Rearranged to alphabetical order 2002-10-23 14:33:23 +00:00
moodler cef08a3a99 Forgot to mention the new LDAP functions! My deep apologies, Petri,
1.0.5 was too long ago - I forgot your plug-in was developed since then!
2002-10-23 14:30:38 +00:00
moodler e870c78bfc WHoops ... just undoing the last checkin which was premature ... 2002-10-23 12:13:47 +00:00
moodler 72c578ca4d Mail now contains Moodle version 2002-10-23 12:12:01 +00:00
moodler cc3b8c75de After saving new question, sanity checks are made to make sure the
fractional grades are correct.

Icons now have tooltips and are also a shortcut to editing page.
2002-10-23 12:10:38 +00:00
compuproggy cbb8979fa9 *** empty log message *** 2002-10-23 07:27:02 +00:00
moodler e7311a0a56 Changed name of upgrade_moodle function to main_upgrade (for consistency) 2002-10-23 04:10:10 +00:00
moodler 3bd87406ba Latest version of Italian from Davide Suraci. 2002-10-23 02:00:16 +00:00
moodler e4814d7f63 cvs update -dP
not

cvs update -d
2002-10-22 13:17:04 +00:00
compuproggy 6fad164f96 *** empty log message *** 2002-10-22 12:36:02 +00:00
moodler f6f0e53de0 Updated information for 1.0.6 Beta 1 2002-10-22 11:21:54 +00:00
moodler ffc5a2c03a More concise feedback on grading, and more efficiency (only update
attempt grades that have changed)
2002-10-22 10:56:48 +00:00
moodler cd63d77e08 Added help pages to quiz module.
A few little cleanups, such as trim() on shortanswers
2002-10-22 10:38:00 +00:00
moodler 377f3c9ee4 new function print_heading_with_help() to print a heading with a helpbutton 2002-10-22 09:54:36 +00:00
moodler f31edeeb88 Display tweaks to table of attempts 2002-10-22 07:03:36 +00:00
moodler e331eb06fd Teacher can now regrade (recalculate grades) of all quiz attempts
(in case the quiz changed somehow)
2002-10-22 06:52:23 +00:00
compuproggy 5ecb135644 *** empty log message *** 2002-10-22 05:37:42 +00:00
moodler 6d86b5dc16 Teacher can now view student attempts 2002-10-22 04:25:58 +00:00
moodler ff99ff634e German should be Deutsche 2002-10-22 02:48:05 +00:00
moodler ede685a73e Fixed name/date variables (don't translate variables!) 2002-10-22 02:34:41 +00:00
moodler 66197f51cc Removed unnecessary mentions of sel@ction 2002-10-22 02:30:36 +00:00
moodler e1c91df09b Can now delete questions. It checks that the question doesn't belong to
any quizzes first (if it's in a published category then it checks all quizzes
on the server).
2002-10-21 15:00:51 +00:00
moodler 34a4dfee10 Added log_display entries for quiz 2002-10-21 14:57:34 +00:00
moodler 2383cadbab Display tweaks 2002-10-21 13:13:33 +00:00
moodler 38f03e5a5c Round $bestgrade when storing it to avoid insert_record problems 2002-10-21 13:02:14 +00:00
moodler 20a3006529 Print intro as HTML 2002-10-21 12:49:28 +00:00
moodler 466a69bc42 Bugfix on calculating correct answers for multichoice questions 2002-10-21 12:48:13 +00:00
moodler e909c8d090 Some error checking 2002-10-21 12:39:46 +00:00
moodler 305ce2b33c Convert intro text to HTML 2002-10-21 11:41:36 +00:00
moodler 840aaba179 Added some more allowed HTML tags 2002-10-21 09:16:06 +00:00
moodler 2a3cda192e Allow teachers to look at ratings for anyone 2002-10-21 08:44:56 +00:00
moodler f166d2e295 Fixed up rating retrieval ... now gets them all seperate 2002-10-21 08:36:15 +00:00
moodler 36df40d60e Fix in forum_grades 2002-10-21 08:32:37 +00:00
moodler 4db9d14dad Don't show column grade when there's nothing to show 2002-10-21 08:19:15 +00:00
moodler caadf00909 Rearranged functions to match other modules, and added forum_grades() 2002-10-21 08:10:24 +00:00
compuproggy fa452aa6f0 *** empty log message *** 2002-10-21 08:06:42 +00:00
compuproggy 15657235ef *** empty log message *** 2002-10-21 08:02:03 +00:00
compuproggy 2ad604fe3c *** empty log message *** 2002-10-21 07:58:18 +00:00
compuproggy 8e44daa729 *** empty log message *** 2002-10-21 07:45:48 +00:00
moodler 912c058651 Grades are not always numbers, so take care in XLS writing 2002-10-21 06:55:01 +00:00
moodler be025399d8 Table header aligns to top 2002-10-21 06:51:56 +00:00
moodler 629e937352 Added journal_grades() so journals show up in the Grades page 2002-10-21 06:42:58 +00:00
moodler 09a4ce320c Changes to toolbar to position color pickers better, and
reintroduce the "select all" button.  Unfortnately, I had
to remove the "About richtext" button to make room
2002-10-21 05:42:37 +00:00
moodler 4168490e17 Added paragraphs to allowed HTML tags 2002-10-21 04:12:54 +00:00
moodler 7bcb78cee3 Modified language so that it speaks to students as well as teachers 2002-10-21 03:23:45 +00:00
moodler 51cc244d12 Added quizzes 2002-10-21 03:04:05 +00:00
moodler e5dfd0f31f Improvements to help, and addition of new "Activity modules" help
for teachers adding new modules.
2002-10-21 03:00:40 +00:00
moodler 2ee53d15ff Some more clues for new admins ... 2002-10-20 18:06:04 +00:00
compuproggy f38aa1ef23 *** empty log message *** 2002-10-20 18:02:40 +00:00
moodler f1edd1922f Updated versions 2002-10-20 17:50:20 +00:00
moodler 3bf89042f5 Whoops, forgot to check in these new icons 2002-10-20 17:42:28 +00:00
moodler b55a466b60 Fixes for display of public categories 2002-10-20 17:41:24 +00:00
moodler c74a0ca5c2 Category editing in quizzes is now supported. Some other little
cleanups along the way ...
2002-10-20 17:15:39 +00:00
moodler f9a9499a62 Guests can no longer see or attempt quizzes 2002-10-20 10:13:04 +00:00
moodler 60f49825a5 New and fixed strings 2002-10-20 10:12:36 +00:00
moodler 16c0beb00b Strip slashes from print_simple_box (just in case) 2002-10-20 10:12:12 +00:00
moodler 4b9b2f0fe4 Fixed display of "done" assignments 2002-10-20 05:35:48 +00:00
moodler 8db3eaddb2 Now shows correct answers, plus some small bug fixes 2002-10-20 05:35:25 +00:00
moodler c1d5710174 Cleaned up format a little, plus added better error checking of server
variables so that at least people will get feedback if they are missing
2002-10-19 04:58:14 +00:00
compuproggy 9b21d119c0 *** empty log message *** 2002-10-18 19:19:35 +00:00
compuproggy 7b1593f040 *** empty log message *** 2002-10-18 17:20:10 +00:00
moodler 7e67441553 Added stuff about the text editing 2002-10-18 17:17:32 +00:00
moodler 0be05df068 Find URLs at the beginning of lines ... 2002-10-18 17:05:17 +00:00
moodler 958aafe2b4 Quiz attempts are now timed. This is done by starting the quiz_attempts
record upon showing the quiz, and completing it upon submit.

Two new fields in quiz_attempts... should be upgrade friendly.
(Old attempts will show up as being of duration zero)


Also some small fixes here and there.
2002-10-18 16:05:21 +00:00
moodler 9f7fd360dd Some tidy ups 2002-10-18 16:02:12 +00:00
moodler aef47af493 Added RTE etc 2002-10-18 16:01:35 +00:00
moodler 291febf79c Improved the documentation (it has some live feedback on the state
of the Richtext functionality)
2002-10-18 11:27:14 +00:00
moodler 18a322490d Cleanup 2002-10-18 09:40:35 +00:00
moodler cf094bd4b4 Better help with text formats 2002-10-18 09:38:58 +00:00
moodler 02a72a36f1 Improved the help page 2002-10-18 09:35:20 +00:00
moodler 2166bb5d7a Language changes and help documentation additions to clearer explain richtext, html and moodle auto-format 2002-10-18 09:29:44 +00:00
moodler d2e186ed71 Revised string for formattext to make more sense 2002-10-18 09:09:54 +00:00
moodler 3fe3851d57 OK, I've rationalised the text formatting now. Basically, both Moodle and
HTML text allow the same range of HTML tags (so it doesn't matter is you
switch from one to the other).

<IMG> and <A> are now ALLOWED in Moodle text.  However, the clean_text
function now checks for and removes any embedded javascript triggers
to avoid cross-site scripting attacks that way.

clean_text() should be called on ANY text that comes in from students.
2002-10-18 09:09:19 +00:00
moodler a0bac19d81 Whoops ... typo. 2002-10-18 09:00:09 +00:00
moodler 57243ffe02 Also set default language on new user created by external authentication 2002-10-18 08:52:33 +00:00
moodler 177e50ed98 New users created by admin also now default to site language 2002-10-18 08:48:44 +00:00
moodler 369622db97 Default language for users is now the same as the site language. 2002-10-18 08:46:12 +00:00
moodler 08beb3327b Allow <IMG> tags in Moodle format text. Not having it can really mess
up smileys etc if the text has been edited at any stage using the
richtext editor.

I realise it's possible for students to really mess up forums display
etc if they wanted to include a huge picture ... I'm not sure if there
are any cross-site scripting attacks possible with images in there.

But there is also now the HTML format for most things, which is editable
using an ordinary form, so this problem is currently already exposed.

I think it's OK as long as can find a filter to strip all javascript
out of ANY format text in Moodle.
2002-10-18 06:05:56 +00:00
moodler e757af1662 Fixed the setting of answers for true-false questions 2002-10-18 05:41:24 +00:00
moodler f9ef3d77d1 Just some better formatting and info 2002-10-18 00:18:26 +00:00
moodler 11a3c89a8f Made transparent 2002-10-17 23:49:02 +00:00
moodler b0e999e646 Changes related to new module 'resource' 2002-10-17 15:32:52 +00:00
moodler 92674bf8bb Changes due to new module 'resource' 2002-10-17 15:14:54 +00:00
moodler 3a5a667386 Changes due to new resource module 2002-10-17 15:10:59 +00:00
moodler 242ee0175f Resulting from module name change 2002-10-17 15:07:22 +00:00
moodler 6c3e8758c6 Changed reading.php to resource.php 2002-10-17 15:03:20 +00:00
moodler 3d58a8b50b Moved from reading module 2002-10-17 14:32:55 +00:00
moodler 4282d7dde2 Changed string neverread to neverseen 2002-10-17 14:28:12 +00:00
moodler 2a439ba7f6 ***NOTE NOTE NOTE **********************************************************
THIS IS A BIG CHANGE!

I've renamed the "reading" module to "resource".

This meant changing quite a few references throughout Moodle.

The automatic upgrade process should work OK (it worked OK on my
development server) and there shouldn't be any problems.

BUT PLEASE PROCEED WITH CAUTION AND KEEP BACKUPS OF EVERYTHING
UNTIL I HAVE A FEW MORE TESTS!   If you upgrade please let me know.

One thing that will break are any hard-coded links within forum messages.

What I will be doing to fix this on my apache server is to add this to
httpd.conf:

Redirect /mod/reading/ http://moodle.com/mod/resource/

Sorry about any inconvenience, but it's better this is done sooner than later.
2002-10-17 14:03:59 +00:00
moodler e1ac42728d Added a 'change password' button 2002-10-17 12:25:25 +00:00
moodler 269eed6448 Changed headers so that it works seamlessly when called from user page. 2002-10-17 12:21:55 +00:00
moodler 952489e16c The grades page now supports downloading of grade data! :-) 2002-10-17 10:34:11 +00:00
moodler 417e6821bd Removed some blank lines that were causing output 2002-10-17 10:33:13 +00:00
moodler 6e770b179c Grr added transparency back again ... 2002-10-17 08:32:29 +00:00
moodler da19305885 Re-adding to overcome CVS strangeness (and my own indecision!) 2002-10-17 08:30:41 +00:00
moodler 9809249838 Better grade reports 2002-10-17 08:28:18 +00:00
moodler e34d323730 Some new strings 2002-10-17 07:58:50 +00:00
moodler 858deff0b4 Now includes maximum grades 2002-10-17 07:55:54 +00:00
moodler d0ac6bc236 Added new grading functions to work with course/grades.php 2002-10-17 07:23:51 +00:00
moodler 3486b7bee5 Added a new grading tool for teachers to see all grades on one page.
Grades are collected from each module using the module_grades function in
each mod/*/lib.php.
2002-10-17 07:23:12 +00:00
moodler 19c4f55c43 Feedback fixes 2002-10-16 15:52:29 +00:00
moodler 5f652ac38e Alt text on moodle logo 2002-10-16 15:48:22 +00:00
compuproggy c5e900c8aa *** empty log message *** 2002-10-16 10:42:35 +00:00
compuproggy 90892fd130 *** empty log message *** 2002-10-16 10:24:09 +00:00
moodler a8a372ccf7 Various fixes and additions. It now does quiz feedback pretty well
(though it doesn't show correct answers yet).
2002-10-16 09:35:04 +00:00
compuproggy 735715779b *** empty log message *** 2002-10-16 09:31:14 +00:00
compuproggy d6aa0e227e *** empty log message *** 2002-10-16 08:48:11 +00:00
moodler 18de986eb1 Actually, let's include journals that have no feedback yet as well. 2002-10-16 07:18:07 +00:00
moodler 8bff8ad835 When a teacher is giving feedback, entries that have been modified since
the last time a teacher has given feedback are highlighted.
2002-10-16 07:15:36 +00:00
moodler b425749fc3 Teacher can now use the richtext editor to edit the assignment text 2002-10-16 05:31:56 +00:00
moodler 7ce20f09cb Changes related to module editing buttons 2002-10-16 04:53:44 +00:00
moodler df2898fe3b Don't show htmleditor preference if it's disabled by admin 2002-10-16 04:52:57 +00:00
moodler 09aebc9468 Cleaned up some buttons ... 2002-10-16 04:51:55 +00:00
moodler 92a3c884f5 Small bugfixes ... (yawn) 2002-10-15 17:32:50 +00:00
moodler 7520988bb3 Fixes for grades 2002-10-15 17:13:11 +00:00
moodler 0a7994a0ba Just updated the number 2002-10-15 16:49:32 +00:00
moodler ab9d6d1e0e Some additions 2002-10-15 16:48:44 +00:00
moodler 55c2620784 Got rid of the wimpy icons in the top-right corner of pages and put some
manly buttons there.  ;-)   I think this will be much clearer for novices,
as well as being a bigger target for experts!
2002-10-15 16:47:43 +00:00
moodler 6b069ecef1 Bit of a clean up of the edit interface ... 2002-10-15 16:45:39 +00:00
moodler 49dcdd1800 Added timeopen and timeclose (instead of days) and did a few cleanups 2002-10-15 16:22:18 +00:00
moodler d197118510 Admin script to brutally delete every file and directory from the
Moodle data directory.  Will be useful for those on hosting servers
without root access.
2002-10-15 16:04:38 +00:00
moodler 8d94f5a08e OK, it seems reliable enough now for alpha testing.
If you have existing quizzes, delete them all, then
drop all the quiz tables and delete the quiz line from
the modules table.

Things to do still:

  - add/edit/remove categories
  - display question feedback on submissions ...
  - record the time they started the quiz, as well as the completion.
  - place time limits between attempts
  - add full specification of quiz open time and quiz close time
2002-10-15 12:54:11 +00:00
moodler 2a2c9725bb Can now create and re-edit all three types of questions.
Still working on grading ...
2002-10-15 10:04:28 +00:00
moodler 2834cce0d9 New strings 2002-10-15 05:31:03 +00:00
moodler 31e7516eb5 Forms now done, more or less 2002-10-15 05:29:57 +00:00
moodler d0030cf051 A little more explicit about PHP requirements 2002-10-15 03:48:04 +00:00
moodler 109613b290 Fix to clear the modform variable just in case there's one
from one module that later affects another module.
2002-10-14 16:06:19 +00:00
moodler ff80e012b0 Miscellaneous little changes from today ... 2002-10-14 16:00:55 +00:00
moodler edecd16dd2 New strings 2002-10-14 15:58:07 +00:00
moodler 10b9291c92 Checking in what I got so far .... Not working yet but I'm going to bed. 2002-10-14 15:57:33 +00:00
moodler 7bd1aa1d64 Quiz generation is working now. Just need question and category editors. 2002-10-14 12:21:18 +00:00
moodler 6a952ce7a0 Many new additions - code not quite usable yet, but getting close 2002-10-14 09:07:13 +00:00
moodler 2eaa2e2861 New strings 2002-10-14 09:04:33 +00:00
moodler 579ddad5ef Added a basic report and some clean-ups 2002-10-13 13:51:56 +00:00
moodler 5c0ee23cc3 Now uses real current language (may not be the same as $CFG->lang) 2002-10-13 10:06:01 +00:00
moodler a5e1f35c66 Just to show that something is happening!
At this stage this module:

  - prints quizzes,
  - accepts answers (for multiple attempts) and grades them,
  - stores the grades.

Really, it's usable as long as you don't mind using the database manually. :)

Next up is quiz reports, then I'll tackle quiz creation.
2002-10-13 07:17:48 +00:00
moodler 5a84640bd1 Tweaks to use new javascript-printing function etc 2002-10-12 15:01:17 +00:00
moodler 3df49694a9 New function to print richtext javascript 2002-10-12 15:00:34 +00:00
moodler 901f9f74e1 First version of German (Deutsch) translation, by Holger.Schadeck@webdesign-forum.de
Great!
2002-10-12 14:33:01 +00:00
moodler e1947876ec Moved the object code out into a function print_textarea 2002-10-12 07:23:16 +00:00
moodler aed0b713fe new string 2002-10-12 06:27:24 +00:00
moodler b2a5ee1822 Added richtext to Journal entries. 2002-10-12 06:20:56 +00:00
moodler 87aa027831 Some notes about the other new stuff. 2002-10-12 05:47:05 +00:00
moodler a5a5a129b7 Added help buttons about the richtext editor (when active) 2002-10-12 05:43:00 +00:00
moodler 66dc0c39d0 Help file for the new richtext HTML editor 2002-10-12 05:39:00 +00:00
moodler 1a072208ce Smilies are now replaced even in HTML text, and small fixes 2002-10-12 05:09:49 +00:00
moodler 75096957ca Keep this one here :-) for the interface 2002-10-12 04:19:51 +00:00
moodler d86cdde20b A bit of info 2002-10-12 04:13:39 +00:00
moodler 0c074a4f2e No longer needed ... replaced by "angry.gif" ... 2002-10-12 04:12:26 +00:00
moodler 2ec69fce6a Added a function useful for debugging Javascript problems 2002-10-12 04:09:51 +00:00
moodler 1581d9b1d8 Swapped clown icon for surprise in the layout ... looks better that way 2002-10-12 04:06:26 +00:00
moodler 696f751f7a Swapped clown for surprise - looks better that way 2002-10-12 04:04:59 +00:00
moodler c828070ac9 Deleted these icons because I'm not using them. The editor now uses
the standard Moodle icons instead.
2002-10-12 04:03:23 +00:00
moodler cd68ebfaef This page now uses the Moodle standard icons for consistency 2002-10-12 03:55:50 +00:00
moodler 84f98bc8a9 Removed references to btnPost because I don't use it 2002-10-12 03:54:56 +00:00
moodler c9dda99059 Modified text_to_html to use the new smilies, which for efficiency are
now defined in a global array, and use str_replace instead of ereg ...
2002-10-12 03:53:40 +00:00
moodler d2aad0a838 Modified this help file to describe the new smilies 2002-10-12 03:51:29 +00:00
moodler c0f4f066c2 Modified all smilies and added some new ones. 2002-10-12 03:50:45 +00:00
moodler 113bb2a26b Better placing of standard links etc when there are lots of images and
other funny formatting in HTML posts
2002-10-11 05:20:23 +00:00
moodler a9ff3d4cdf New strings to do with language direction 2002-10-11 02:32:05 +00:00
moodler 541117b6cb Changes to support choice of language direction (so that languages
like Arabic, Hebrew etc will work)
2002-10-11 02:31:37 +00:00
moodler 4b9318947c Added a new string to make it very clear how to upload assignments 2002-10-11 01:58:24 +00:00
moodler 213e8cc67d Better default options, and hiding of moodle-text help when htmlediting is operational 2002-10-10 09:27:49 +00:00
moodler c4a4cae062 Added another translator for Finnish 2002-10-10 07:29:44 +00:00
moodler da061bb457 Added option to choose HTML editor 2002-10-10 07:29:09 +00:00
moodler 73bb08357c Initial attempt at adding html text editor features to these forms. 2002-10-10 07:27:57 +00:00
moodler d2fce839b6 Updated the version (database table addition user->htmleditor) 2002-10-10 07:27:07 +00:00
moodler 0095d5cd3c Additions to cope with richtext editor being used in some forms. 2002-10-10 07:26:10 +00:00
moodler fa7d70c8c1 Added new strings 2002-10-10 07:24:59 +00:00
moodler de909d238d Adding a beta version of Rich Text Editor, for embedding into Moodle
forms (forums, readings, journals etc).  Works only on IE 5.5 and later.

Slightly customised for a slimmer toolbar.
2002-10-10 07:21:32 +00:00
moodler bc0750aaae Arg .. so much for quick hacks ... this code is so messy it's
a hassle to hack ... going back to the way it was originally, with
just a more informative error message instead.
2002-10-09 14:20:24 +00:00
moodler 0bdce31166 Changes to avoid cryptic errors 2002-10-09 14:08:33 +00:00
paca70 b54cd88f34 More corrections, documentation is coming. 2002-10-08 15:51:27 +00:00
moodler b1f2587a65 Latest changes for Italian version, by Davide Suraci 2002-10-08 02:09:43 +00:00
paca70 80f4bff33e Initial version 2002-10-07 17:17:33 +00:00
paca70 2cfd9e4dc9 Some corrections 2002-10-06 18:41:38 +00:00
paca70 66ea86f3b8 Initial version 2002-10-06 18:24:14 +00:00
moodler f3632647e7 Empty file 2002-10-06 17:31:46 +00:00
moodler 8e7ad7283b New words 2002-10-06 17:20:54 +00:00
moodler f8e4809a03 New function print_file_picture for printing a picture from the
files area, or optionally from a URL
2002-10-06 17:20:32 +00:00
moodler 14d8c0b409 Further work done. It currently can print the quiz form (including images!)
but can't mark them yet.  I've been constructing quizzes manually in the
database and it's helping to refine the database structure.  Don't count
on anything stable in the quiz module for a few days yet ...
2002-10-06 17:06:54 +00:00
moodler 55c0c75c03 A start on the page that actually prints the questions and stores the answers 2002-10-06 03:24:56 +00:00
moodler 36658798dc More or less working now 2002-10-06 03:23:34 +00:00
moodler 3a506ca299 Added some more functions 2002-10-06 03:23:16 +00:00
moodler 765814def3 Changed includes of module libraries to use full pathnames constructed
from $CFG->dirroot, rather than relative.  This is because the relative
path could sometime be a different case to the full path (on Windows)
causing include_once not to work.
2002-10-06 03:05:22 +00:00
moodler f01826ee39 Moved module upgrading functions out into database-specific files 2002-10-05 17:21:39 +00:00
moodler c0d6bcc508 Moved upgrade functions into db/mysql.sql 2002-10-05 17:20:24 +00:00
moodler 31f0900c61 Moved upgrade_moodle functions out to database-specific files, because
the SQL is not compatible (nor is it possible to make it so).
2002-10-05 17:09:31 +00:00
moodler e858f9da96 create_new_user() can now import other fields from an external source
if the function for it has been defined.  (Petri's code with additions by me)
2002-10-05 16:49:42 +00:00
paca70 2a86e7a1a5 More corrections 2002-10-04 13:07:16 +00:00
moodler 730fd187c8 Skeleton version of the quiz module. It won't break an installation,
but it doesn't do anything yet.
2002-10-04 02:59:05 +00:00
moodler 518d37151d Use main version of "maximum grade" string 2002-10-04 02:55:27 +00:00
moodler b2a82ad65c Make names into a list 2002-10-04 02:54:53 +00:00
paca70 7d3e684292 and some more.... 2002-10-03 17:10:50 +00:00
paca70 75ebf527c9 Some fixs more. 2002-10-03 17:04:15 +00:00
paca70 a08db54a84 Translated new strings and fixed some old ones. 2002-10-03 16:54:58 +00:00
paca70 68605943ae Corrected some comments. 2002-10-03 15:55:45 +00:00
paca70 fcad13730e Initial version of ldap authentication module. It have no config-interface yet. (But it's coming)
It contains also experimental auth_get_userinfo() function, what is not used by moodle yet.
If you like to try it, create following $CFG variables to /config.php or directly to config-table and activate
ldap authentication from admin-configuration page.

$CFG->ldap_bind_dn      	"If your like to use bind-user to search users, specify it here. Someting like 'cn=ldapuser,ou=public,o=org'"
$CFG->ldap_bind_pw      	"Password for bind-user."
$CFG->ldap_contexts    		"List of contexts where users are located.
				  Separate different contexts with ';'. Something like 'ou=users,o=org; ou=other,o=org'"
$CFG->ldap_host_url      	"Specify LDAP host in URL-form like 'ldap://ldap.myorg.com/' or 'ldaps//ldap.myorg.com/' ";
$CFG->ldap_search_sub   	"Put value <> 0 if  you like to search users from subcontexts.";
$CFG->ldap_user_attribute 	"What attribute is used to name/search users. Usually 'cn'. ";

More configuration optios are coming. This version is tested against Novell E-Directory without SSL and it works fine.
2002-10-03 13:45:19 +00:00
moodler abf59b15bd Fixed definition of forum->open 2002-10-03 11:17:51 +00:00
moodler 70c476a79e Fixes bug 112
Changes to expand "open" option in forums.  Now have a choice between
three options:  new discussions and new replies, new replies only and
no new discussions or new replies.

Three new options in lang/forum.php and I changed "allowdiscussions".
2002-10-03 11:15:50 +00:00
moodler 7d95ed97c7 User's name in footer is now a link 2002-10-03 11:11:53 +00:00
moodler 8dbed6be60 format_time() now supports language strings for day(s)/hour(s)/min(s)/sec(s)
String lookups are cached in user/index.php for efficiency
2002-10-03 04:04:59 +00:00
moodler 05d09aa1f9 Just making this more relevant for the CVS update junkies :-) 2002-10-03 03:55:03 +00:00
moodler a168bd029f Expanded the description and included sample commands 2002-10-03 03:35:53 +00:00
moodler 7b5baeb7de "Activities" wasn't being taken from language files 2002-10-03 02:57:36 +00:00
paca70 4b76aa52d0 Minor update to test that update rights are working. 2002-10-02 19:37:35 +00:00
moodler 5251893741 Fixes for accented characters 2002-10-02 16:23:12 +00:00
moodler 5c958cabcc Updated a word 2002-10-02 15:55:22 +00:00
moodler 168fe1427a New version number for development 2002-10-02 14:43:04 +00:00
moodler 3eb4b24fed Added 'thischarset' = "iso-8859-1", for completeness 2002-10-02 14:20:30 +00:00
moodler 59857bd7a8 Checked in initial Italian version by Davide Suraci, with help from others 2002-10-02 13:50:36 +00:00
moodler 3763e302ff Added Sebastien Nameche 2002-10-02 10:59:04 +00:00
moodler 0cb8bf3bcd Locale box is a bit bigger, since locale strings can be bigger :-) 2002-10-02 10:35:43 +00:00
moodler 3a178d04d1 Removed configcharset, but kept thischarset 2002-10-02 10:34:31 +00:00
moodler 4bfa92e714 Added new header to all pages to set the current charset, to help browsers 2002-10-02 10:33:05 +00:00
moodler 53e61ab906 Updates to the French translation, by M. Sebastien Nam?che 2002-10-02 09:37:29 +00:00
moodler 0ebe961a18 A change to test the ACLs 2002-10-02 08:23:49 +00:00
moodler a1122760d0 Changes 2002-10-02 07:59:22 +00:00
moodler 39df7c9774 Fixed links to be relative. This prevents errors on the offchance that
the current URL != $CFG->wwwroot/login
2002-10-02 07:08:56 +00:00
moodler 2e60a1ace3 Made these images transparent 2002-10-02 05:10:10 +00:00
moodler b4ab71a6db Fixed links in navigation 2002-10-02 02:24:19 +00:00
moodler 7fbd6b1c0b Don't use getenv anywhere - not necessary and breaks PHP under ISAPI 2002-10-02 02:05:29 +00:00
martin e99af4408f CHANGES UP TO 1.0.5 2002-09-27 15:14:04 +00:00
martin cc300ceb39 Mentioned newly allowed tags 2002-09-27 15:03:28 +00:00
martin 8dcea3963a Added a few more allowed HTML tags in plain text files. <dl> <h1><h2><h3> <hr> 2002-09-27 14:48:25 +00:00
martin dfb6e4ac3e Tweaks to page titles to make them more consistent 2002-09-27 14:26:02 +00:00
martin 0d399dc585 Aaaahhh I remember now why this was in here, because in future there might
be course-level themes and user-level themes.

Putting it back as before ... :-)
2002-09-27 14:19:59 +00:00
martin cd1c4d2321 Removed theme chooser from here ... moving it to admin folder 2002-09-27 14:18:06 +00:00
martin 555bdfc813 Fixed a little link to login page 2002-09-27 13:44:52 +00:00
martin d51c583d3c Updated version for 1.0.5 release 2002-09-27 13:40:17 +00:00
martin ebf2e54dd6 Mentioned the icon bug 2002-09-27 13:39:59 +00:00
martin 5ea4745d18 Updated version and release 2002-09-27 06:20:20 +00:00
martin 077f9a67d0 Add manage database link to home page admin links if necessary 2002-09-27 06:19:49 +00:00
martin 34a0cda676 Put version info on admin page 2002-09-27 06:19:18 +00:00
martin b35f948b97 Nicer way to find out the major changes since the last version.
RELEASES.html shows the changes, and these are displayed during
an upgrade.
2002-09-27 06:13:59 +00:00
martin 2802ac6ec7 Tweaks and formatting 2002-09-27 05:25:46 +00:00
martin 2a691b9439 Hoepfully made the upgrade process clearer. 2002-09-27 05:12:02 +00:00
martin 91ac0405fa A little extra error checking. 2002-09-27 04:53:27 +00:00
martin 3ef909ca58 Removed encoding setting because i suspect it may be messing with SMTP mail 2002-09-27 01:35:25 +00:00
martin b362b85e99 Better format for text version of emails 2002-09-26 16:02:13 +00:00
martin 004db95014 Changed some instances of include() to include_once() 2002-09-26 14:41:59 +00:00
martin f1f901c3ea After upgrading version, stay on admin page rather than going to home
page, just in case there is more to do.
2002-09-26 13:05:18 +00:00
martin 9450cef212 Updated version and release 2002-09-26 11:44:06 +00:00
martin f25f1e1b66 Little bug that caused the guest icon to display even when guest was turned
off (if the password was null)
2002-09-26 11:10:20 +00:00
martin 57f3a4a564 the more things change, the less they stay the same 2002-09-26 07:27:01 +00:00
martin 41e1986cdc Update the version 2002-09-26 07:25:47 +00:00
martin 8f1cba2858 The login page now shows different instructions depending on the
authentication mechanism.
2002-09-26 07:13:14 +00:00
martin faebaf0f40 First implementation of new authentication system, which can now use
pluggable modules in the 'auth' directory.

Everything is done through authentication_user_login in lib/moodlelib.php

As well as the old default "email" confirmation, I added a new type of
confirmation "none", which basically does no confirmation at all.
2002-09-26 07:03:22 +00:00
martin ab998e5d07 Check for USER->email in require_login. With external authentication
schemes it's possible that the email field could be empty, so this
will force users to update it (and the rest of their profile) any
time they log into a course.
2002-09-26 03:51:31 +00:00
martin 43dc944611 Make $a bold so it's easier to see 2002-09-26 03:36:16 +00:00
martin ef5e5d87dc New help file for language editing 2002-09-26 03:20:15 +00:00
martin 4c2bcc7a1b Much better. No slashes needed AT ALL now, not even for $a variables.
Also provided a help button at the top.
2002-09-26 03:16:40 +00:00
martin 9d389960e6 Patches from Petri 2002-09-26 02:19:53 +00:00
martin d7ea4a225d Info about lib/htaccess 2002-09-25 16:38:09 +00:00
martin 96dad0de43 Added DirectoryIndex stuff 2002-09-25 16:33:54 +00:00
martin 7104dfc9ef Added new postgres7 schema, developed by Felipe Rodrigues da Silva <felipe@pontoexe.com>. Thanks Felipe!
I've personally not tested this yet so PostgrSQL user feedback is encouraged!
2002-09-25 15:16:21 +00:00
martin b839163528 Don't redirect too early 2002-09-25 14:40:28 +00:00
martin d66ee54d8d Add some comments 2002-09-25 13:37:12 +00:00
martin 04ad372d93 Improved explanations for how to use this file 2002-09-25 12:33:21 +00:00
martin 632d640751 It's possible $USER->lang may not be defined. If so, use $CFG->lang. 2002-09-25 11:06:27 +00:00
martin 4c701e6f54 Set fromdiscussion here just in case it's not set elsewhere 2002-09-25 08:17:35 +00:00
martin 38ff0e9f1f ALL CHANGES UP TO MOODLE 1.0.5 BETA 1 2002-09-25 07:42:39 +00:00
martin 9ec9ff5dc5 Unfinished files 2002-09-25 07:41:23 +00:00
martin 89e71738b5 updated version numbers for beta 1 release 2002-09-25 07:40:07 +00:00
martin 9806ae9403 README contains author etc 2002-09-25 07:38:23 +00:00
martin d68c814679 Added README with author 2002-09-25 07:37:31 +00:00
martin d0b12add53 Author stored in README 2002-09-25 07:35:58 +00:00
martin cb011cfd0a In compare mode you can now EDIT language files directly. This should
make language development much easier.

Based on code sent to me by Petri Asikainen
2002-09-25 07:33:04 +00:00
martin f74a4a79f2 Cough typo 2002-09-25 07:31:19 +00:00
martin 6321ab8df6 Edited using language editor 2002-09-25 07:30:16 +00:00
martin 3f5331eb19 New string 2002-09-25 07:19:32 +00:00
martin 49f5bb0527 Fix for ICQ display (they've changed their URLs) 2002-09-24 12:45:06 +00:00
martin ed4567d69d Hide password during registration 2002-09-24 09:20:43 +00:00
martin 74ed07ac86 Prevent guests even seeing the edit button 2002-09-24 09:06:17 +00:00
martin 3182314d5c Prevent guests from submitting choices or assignments 2002-09-24 09:02:34 +00:00
martin 17b365f829 Updated Sebastien's address to seb@gaia.anet.fr 2002-09-24 08:54:44 +00:00
martin 3d98b29d51 Make sure site security is added when logging in via change password 2002-09-24 01:28:19 +00:00
martin 83e9a09e34 Newly formatted header.html files in themes ... still works the same
just might be easier to edit now.  index.php uses new set_config function
2002-09-23 15:42:22 +00:00
martin 8cea3a3974 Special "navigation" for home page - "home" value sets off different header
in themes
2002-09-23 15:41:06 +00:00
martin a28af1fe74 New set_config() and better use of $CFG->version 2002-09-23 15:40:16 +00:00
martin b3ac9d9b85 New standardlogo theme ... like standard but with a logo 2002-09-23 15:38:22 +00:00
martin fd8dfb5a88 Sample logo 2002-09-23 15:37:08 +00:00
martin 1e22462d01 Fixed up default-sized tables again 2002-09-23 07:02:26 +00:00
martin 7fd6bb7cf6 Whoops teacher checking was back to front 2002-09-23 06:49:30 +00:00
martin 380871ace1 Personal mentions 2002-09-23 04:04:31 +00:00
martin a46b910e00 Change to name of language 2002-09-23 02:11:08 +00:00
martin 43afb07b98 Updated name of language 2002-09-23 02:08:40 +00:00
martin 3e8540f4fe Added Portuguese (Brazilian) by Fabricio Valadares, Thanks! 2002-09-23 02:04:44 +00:00
martin 2b6277bc51 Updated credits 2002-09-23 01:47:34 +00:00
martin affb83a226 Saner format for editing profile 2002-09-22 16:24:38 +00:00
martin 1fdaab8d76 Bolder title 2002-09-22 16:19:45 +00:00
martin a58977a2a0 Forgot country display change 2002-09-22 16:17:11 +00:00
martin adcb3ac53d Better country sorting on user index in a course 2002-09-22 16:16:13 +00:00
martin 7c3cf7f3ef Better way of sorting countries 2002-09-22 16:12:49 +00:00
martin 096dc19f3b Fixes to country sorting 2002-09-22 16:03:01 +00:00
martin 8538258121 Better handling of country sorting 2002-09-22 15:57:23 +00:00
martin 66c95f3224 Don't delete a user if already deleted (reloading page, say) 2002-09-22 14:42:32 +00:00
martin 6968fd6656 Updated version 2002-09-22 14:39:09 +00:00
martin 45aa6d563c Fixes to unenrolling students, and unenrol_student() and remove_teacher()
now remove forum_subscriptions correctly
2002-09-22 14:33:21 +00:00
martin 274f62e6d5 Fixes to table widths 2002-09-22 14:11:45 +00:00
martin b4ead712f2 Arrghh ... foget to remove the debugging thing 2002-09-22 14:07:15 +00:00
martin d578afc883 Major cleanup of user administration and display, including sortable listings,
confirmation on deletions, removing deleted user from all student lists,
teacher lists and subscription lists and freeing up their username and
email to be used again.
2002-09-22 14:06:38 +00:00
martin 7684ce4b32 Changes (getting close to 1.0.5 now) 2002-09-22 06:49:38 +00:00
martin 1d3ff0711f Updated module template with module_print_recent_activity() 2002-09-22 06:47:11 +00:00
martin 3446205d44 Added assignments under "Recent Activity" 2002-09-22 06:41:56 +00:00
martin 88491cacba When redirecting to admin page go direct to index.php just in case
DirectoryIndex hasn't been fixed yet.
2002-09-22 05:33:54 +00:00
martin bbe3efd8e1 Some comments to indicate standard and other functions 2002-09-22 04:29:18 +00:00
martin 66ea15f3cc Reaaranged the functions into standard and other 2002-09-22 04:27:45 +00:00
martin 7bca79576f Fixed stupidity 2002-09-22 03:58:41 +00:00
martin a30cfe1685 Error in the SQL - fixed now 2002-09-22 03:57:56 +00:00
martin 54634efcba New function to show new surveys in recent activity box 2002-09-22 03:51:28 +00:00
martin a2b71b6d71 Whoops typo - left in some old stuff 2002-09-22 03:17:29 +00:00
martin 03af47eee3 SHow number of journal entries in the teacher link to report 2002-09-22 03:16:40 +00:00
martin 3bf90da5f6 Use log URL for link to journal 2002-09-22 03:13:10 +00:00
martin 01a086c3dd Support for new deleted field in user table 2002-09-22 03:11:05 +00:00
martin ae2e0dddad Changes to not include deleted users in some things 2002-09-22 03:05:39 +00:00
martin bb09fb1157 Changes to enable DELETION of user accounts. Accounts aren't actually
deleted, they are just marked with a deleteion flag that prevents them
from logging in, or from being listed anywhere.
2002-09-22 03:01:17 +00:00
martin 3869a2ac3d Changes to print_recent_activity in course/lib.php. It is now more
modular (at slight cost to performance) and every modules can now
have a module_print_recent_activity() function.  This function
takes a list of logs, searches for things to display and does so.

So far I've done forum and journal functions
2002-09-21 17:11:08 +00:00
martin 20aa2257dc Allow 1-minute delay (mostly good for testing) 2002-09-21 08:44:08 +00:00
martin 93e0f85d6c Need more room for language variable (eg pt_br) 2002-09-21 08:42:05 +00:00
martin a16c2180d0 Make sure user language works OK (it does now) 2002-09-21 08:40:27 +00:00
martin 562bbe9074 Make mail format explicitly 8bit 2002-09-21 08:39:54 +00:00
martin a5a4cd60cb Make sure mailouts are in the user's chosen language 2002-09-21 07:46:30 +00:00
martin 5319c6adf6 Make sure mailouts are in the chosen language of each user 2002-09-21 07:42:54 +00:00
martin bcf7ee7a97 Initial (incomplete) version of French translation by Sebastien Nameche <snameche@virtual-net.fr>
Good start!  Thanks, Sebastien.
2002-09-21 07:27:07 +00:00
martin 94cfe58b19 Initial version of Finnish translation, as done by Petri Asikainen <paca@sci.fi>
Thanks, Petri!
2002-09-21 07:22:23 +00:00
martin 1774e33325 Added single quotes around all the keys ... even though PHP works
without them, it will flag errors when errorlevel is turned up, and
I suspect this slows it all down a bit.
2002-09-21 07:18:16 +00:00
martin 13fb5ec074 Added my email address 2002-09-21 07:07:44 +00:00
martin effbcca27c Don't need to log in to see site-level course 2002-09-21 07:03:54 +00:00
martin b92ea9450c More options for longtimenosee 2002-09-21 06:45:26 +00:00
martin c69ce08b49 Don't print pictures at all for very large lists 2002-09-21 06:39:28 +00:00
martin 25fa226dac Make more room in list 2002-09-21 06:30:32 +00:00
martin 32b4b9746a more refinements to sorting display 2002-09-21 06:27:00 +00:00
martin 3f63219688 Fixed typo from testing 2002-09-21 06:13:42 +00:00
martin e6b9ee042d Much better look for user index 2002-09-21 06:12:54 +00:00
martin dccd16712a Slight additions to print_table 2002-09-21 05:43:46 +00:00
martin c07daf5bbc Added lang for users 2002-09-21 05:43:21 +00:00
martin 6b281f1fec Better display of users in shortened form, for testing 2002-09-21 05:42:16 +00:00
martin 7a702c34ea Tweak 2002-09-20 15:42:16 +00:00
martin 6abee98964 First go at an abbreviated user listing 2002-09-20 15:40:20 +00:00
martin 1e4d8ed1d2 Put sitename on debugging info (helpful when comparing two sites) 2002-09-19 14:59:47 +00:00
martin 08056730fa Improved interface for course/teachers.php ... instead of typing numbers
into a box there is now a menu for each user.   Much better!
2002-09-19 14:51:49 +00:00
martin ae7aafeb53 Got rid of errorlevel configuration - more trouble than it's worth!
Hardcoded it into setup.php now - people who are that keen can change
it there.
2002-09-19 14:07:24 +00:00
martin 1be8717562 Updated for new configuration page 2002-09-19 14:06:28 +00:00
martin 4d0dde9159 Some consistency in headers on editing forms 2002-09-19 13:55:40 +00:00
martin 74944b734d Most of the configuration variables have been moved out of the config.php
file and into a database, where they can be edited using a new admin form
called "Configure variables".
2002-09-19 12:01:55 +00:00
martin e80e60a6b2 Slight fix to error page to include site name properly 2002-09-17 14:56:18 +00:00
martin 76dbe04f4a Login link on home page 2002-09-16 13:03:31 +00:00
martin 7ff602b225 eminder about saving themes in upgrades etc 2002-09-16 07:11:31 +00:00
martin a9858957e1 Typo 2002-09-16 07:08:33 +00:00
martin 7185779262 Fixed name in popup javascript window 2002-09-16 07:03:33 +00:00
martin af90e74e59 Sample .htaccess file 2002-09-16 06:33:53 +00:00
martin 37e9df195f Fixed Id 2002-09-16 03:23:10 +00:00
martin c94e1535f8 Type on phpinfo 2002-09-16 03:20:55 +00:00
martin 7b5271354b Mentioned there's no need to use a trailing slash on the wwwroot 2002-09-15 06:09:44 +00:00
martin a7b9e8bc9f Fixes to point directly to index.php wherever it was assumed. This wasn't
a problem on most servers, but was causing some problems on IIS servers
2002-09-15 06:06:32 +00:00
martin 1a72314d0f Can now specify current language on a per-user basis 2002-09-14 03:43:24 +00:00
martin c46df33643 New help file for editing html 2002-09-13 10:22:06 +00:00
martin 73761dc9be Added a new reading type "html text". It's similar to "plain text"
except none of the auto-formatting is done, and all HTML code is
accepted.
2002-09-13 10:21:03 +00:00
martin ddd9a8969b SUrprise icon is a bit wider than 16 pixels 2002-09-12 17:08:32 +00:00
martin 7ef459ebed Fixed bug with category links on front page 2002-09-12 02:42:22 +00:00
martin e31309ed79 One more little buglet when confirming an email (added security site value) 2002-09-11 14:02:30 +00:00
martin 91d5dbf3eb CHANGES UP TO 1.0.4 (really, I mean it this time :-) ) 2002-09-11 05:11:13 +00:00
martin 122cffc938 Include guest user in list of users 2002-09-11 02:26:56 +00:00
martin 0c6561819b Changes to course display on front page when there is more than one category 2002-09-10 13:47:56 +00:00
martin 4ea0fc0f1a Removed some debugging stuff 2002-09-10 13:24:24 +00:00
martin a789fb73f4 More security for email confirmation process ... a 15-character random
"secret" key is stored the user record on account creation, sent via
email and checked again during confirmation.
2002-09-10 12:54:01 +00:00
martin ceb7ea7550 CHANGES UP TO 1.0.4 2002-09-10 03:44:09 +00:00
martin 99b5e56207 Whoops, left attachment field out of the database schema (affected
new installations of 1.0.2 and later)
2002-09-10 02:13:44 +00:00
martin 45c58cb7ad CHANGES (this is 1.0.4 unless anything comes up very soon) 2002-09-09 15:52:07 +00:00
martin 8e652a3660 Tweak to modify interface a bit (changed header and made courses a link) 2002-09-09 15:50:55 +00:00
martin db95b60308 CHANGES 2002-09-09 12:38:29 +00:00
martin 0a26320532 Tweaks to category display 2002-09-09 12:37:34 +00:00
martin ba2e5d7347 Categories upgrade. Admin can now create/edit/delete categories, and
these are diesplayed wherever courses are listed
2002-09-09 11:48:11 +00:00
martin 7aa0bb8886 Layout fixes ... much better now 2002-09-09 11:42:27 +00:00
martin d6935726ed Changed maximum number of weeks/topics up to 52 2002-09-09 11:31:48 +00:00
martin 782e7594ec Rearrange code ... accidentally placed table->head in the loop 2002-09-09 10:38:14 +00:00
martin e5c2a9e441 Whoops ... last conversion actully tampered with comment formatting
... I've fixed that now.
2002-09-09 06:23:39 +00:00
martin bc44a3a0ad Converted all the DOS format text files to UNIX format, for consistency
with the rest of Moodle and also to prevent possible mangling of
files in case they are FTP'd individually to a server.
2002-09-09 06:17:11 +00:00
martin 503eced327 Added height and width to smiley icons, to make emails look
better in circumstances where external images are blocked
(eg some webmail programs like squirrelmail).
2002-09-08 16:13:10 +00:00
martin 8f66d49a77 Added an "unsubscribe" link to emails 2002-09-08 16:04:51 +00:00
martin 28e1e8b912 Fixed a bug. When replying to an email copy, you would be forwarded
to the login screen to login first.  However, this was being saved
as the place to go back to after replying.

I added a check for this so now it behaves as you'd expect.
2002-09-08 15:39:44 +00:00
martin cdf6a3ca28 Text window a bit bigger 2002-09-08 09:47:10 +00:00
martin cd3fccff00 Choices now support up to 6 choices. Backward compatible to 2-choice format. 2002-09-08 09:42:07 +00:00
martin 2415d953f0 Tip over 'Edit profile' is the user's name 2002-09-08 09:41:17 +00:00
martin d037d3a28a Help for choices 2002-09-08 09:22:31 +00:00
martin 59a7100ccf Clarified the "participants" link ... 2002-09-08 05:29:00 +00:00
martin 2c26c98575 Link at bottom now goes to site home, not this page 2002-09-08 05:23:47 +00:00
martin 09442e5067 Added documentation to the teachers page. 2002-09-08 05:15:52 +00:00
martin 5b54db6ee4 Improved print_table() a bit (can now specify column widths) 2002-09-08 05:15:37 +00:00
martin c2bc0a4573 Need this file to go with the previous changes! 2002-09-08 03:34:45 +00:00
martin 40a1d986f9 Changes to improve display of teachers 2002-09-08 03:34:12 +00:00
martin b4d7002e66 Changes to allow much better control over what "teachers" are called
in a course.  Firstly, the course settings page now allows the teachers
to specify the word they want to use in place of "teachers" and "students"
as well as "teacher" and "student".  Secondly, a new teacher admin tool
allows any teacher to modify the order and displayed role of teachers
in that course.  This affects the display on the course listings, the
participants page and so on.
2002-09-08 03:24:38 +00:00
martin 774ab66002 Improvements to the language checker. As well as checking for missing
strings, you can now see the current language compared side-by-side
with English.
2002-09-07 14:57:33 +00:00
martin 7fb8331432 Add a link if a "manage database" directory exists 2002-09-07 14:56:19 +00:00
martin fa8e1a34ec Slight update to README 2002-09-07 05:01:55 +00:00
martin 601212b8d2 Added a README that explains the process 2002-09-07 03:54:10 +00:00
martin a48bf3ecd4 Added a template for new modules that contains the bare necessities. 2002-09-07 03:31:36 +00:00
martin 12bace2439 Checking in the current release number for CVS users 2002-09-06 15:17:44 +00:00
martin d21fef3a02 Don't try and print the last access date if it doesn't exist 2002-09-06 15:10:36 +00:00
martin c646b70d66 Added a new $release variable that shows the user-friendly version number 2002-09-06 14:06:48 +00:00
martin 7c6addde73 Cleaned up a bit 2002-09-06 14:05:43 +00:00
martin 09ba0c8a32 Fixed bug in password checking for new admin user ... 2002-09-05 17:31:08 +00:00
martin c5e66fc9da Updated the info to mention that the upgrading only works if you
are logged in as the *administrator* and visit the site home page.
2002-09-05 12:29:26 +00:00
martin 19505e1333 CHANGES UP TO 1.0.3.1 2002-09-05 12:25:08 +00:00
martin 19967d6c3d Updated version 2002-09-05 12:24:15 +00:00
martin 55b8ac3107 Better error message when invalid arguments are supplied. 2002-09-05 11:56:20 +00:00
martin e2d8972553 BUG FIX! - fixes error that could allow ANY file on the system to be read! 2002-09-05 11:53:17 +00:00
martin 45f21575aa Whoops ... little bug that stopped loginas from working ... need to
create $USER->site ...
2002-09-05 11:28:06 +00:00
martin f5e88127d8 Updated version number 2002-09-05 02:29:54 +00:00
956 changed files with 51465 additions and 5348 deletions
+5554 -161
View File
File diff suppressed because it is too large Load Diff
+39 -32
View File
@@ -1,32 +1,39 @@
README $Id$
------
Here is a basic outline of the installation process,
which normally takes me only a few minutes:
1) Move the Moodle files into your web directory.
2) Create an empty directory somewhere to store
uploaded files (NOT accessible via the web).
This directory must be writeable by the web server
process.
3) Create a single database for Moodle to store all
it's tables in.
4) Copy the file config-dist.php to config.php, and
edit it with all your own settings.
5) Visit your new home page with a web browser. Moodle
will lead you through the rest of the setup,
creating an admin account and so on.
6) Set up a cron task to call the file admin/cron.php
every five minutes or so.
For more details, I highly recommend you read the
full installation documentation, which is stored
in the "doc" directory or found at http://moodle.com/doc/.
Cheers!
Martin Dougiamas
README $Id$
------
I highly recommend you read the detailed help on
installation, upgrading and use of Moodle, stored
in the doc subdirectory of this installation, or
read at:
http://moodle.com/doc/
For the impatient, here is a basic outline of the
installation process, which normally takes me only
a few minutes:
1) Move the Moodle files into your web directory.
2) Create an empty directory somewhere to store
uploaded files (NOT accessible via the web).
This directory must be writeable by the web server
process.
3) Create a single database for Moodle to store all
it's tables in.
4) Copy the file config-dist.php to config.php, and
edit it with all your own settings.
5) Visit your new home page with a web browser. Moodle
will lead you through the rest of the setup,
creating an admin account and so on.
6) Set up a cron task to call the file admin/cron.php
every five minutes or so.
Cheers!
Martin Dougiamas
-42
View File
@@ -1,42 +0,0 @@
UPGRADING $Id$
---------
As Moodle grows, there are changes to the code and
sometimes changes to the database structures.
Moodle is able to upgrade its own databases, using
information in files called version.php. There is
one of these for the main tables (in this directory)
and one for each module.
When upgrading from any previous version of Moodle,
all you normally will need to do is this:
1) Make a backup of your current Moodle installation
in the unlikely case that something goes wrong and
you need to restore the older version.
2a) If you are using CVS, just go the root directory
and type "cvs update -d" (or whatever the equivalent
is on your non-Unix server).
OR
2b) Remove the current installation, and then unpack
the new tar or zip file in the same location.
Make sure you copy the config.php file from your
old installion to the new installation (or make a
new one by editing config-dist.php).
3) Visit the home page of your installation. Moodle
will automatically detect the new version and perform
any database upgrades that might be necessary.
If all goes well (no error messages) then you can just
go on using Moodle normally.
If you have problems with this procedure, let me know.
Cheers,
Martin
+142
View File
@@ -0,0 +1,142 @@
<?PHP // $Id$
// config.php - allows admin to edit all configuration variables
include("../config.php");
require_login();
if (!$site = get_site()) {
redirect("index.php");
}
if (!isadmin()) {
error("Only the admin can use this page");
}
/// If data submitted, then process and store.
if (match_referer() && isset($HTTP_POST_VARS)) {
$config = (object)$HTTP_POST_VARS;
validate_form($config, $err);
if (count($err) == 0) {
print_header();
foreach ($config as $name => $value) {
if (! set_config($name, $value)) {
notify("Problem saving config $name as $value");
}
}
redirect("auth.php", get_string("changessaved"), 1);
exit;
} else {
foreach ($err as $key => $value) {
$focus = "form.$key";
}
}
}
/// Otherwise fill and print the form.
if (!isset($config)) {
$config = $CFG;
}
$modules = get_list_of_plugins("auth");
foreach ($modules as $module) {
$options[$module] = get_string("auth_$module"."title", "auth");
}
asort($options);
if (isset($_GET['auth'])) {
$auth = $_GET['auth'];
} else {
$auth = $config->auth;
}
if (! isset($config->guestloginbutton)) {
$config->guestloginbutton = 1;
}
$guestoptions[0] = get_string("hide");
$guestoptions[1] = get_string("show");
$stradministration = get_string("administration");
$strauthentication = get_string("authentication");
$strauthenticationoptions = get_string("authenticationoptions","auth");
$strsettings = get_string("settings");
print_header("$site->shortname: $strauthenticationoptions", "$site->fullname",
"<A HREF=\"index.php\">$stradministration</A> -> $strauthenticationoptions", "$focus");
echo "<CENTER><P><B>";
echo "<form TARGET=\"_top\" NAME=\"authmenu\" method=\"post\" action=\"auth.php\">";
print_string("chooseauthmethod","auth");
choose_from_menu ($options, "auth", $auth, "","top.location='auth.php?auth='+document.authmenu.auth.options[document.authmenu.auth.selectedIndex].value", "");
echo "</B></P></CENTER>";
print_simple_box_start("center", "100%", "$THEME->cellheading");
print_heading($options[$auth]);
echo "<BLOCKQUOTE><CENTER><P>";
print_string("auth_$auth"."description", "auth");
echo "</P></CENTER></BLOCKQUOTE>";
echo "<HR>";
print_heading($strsettings);
echo "<table border=\"0\" width=\"100%\" cellpadding=\"4\">";
require("$CFG->dirroot/auth/$auth/config.html");
if ($auth != "email" and $auth != "none") {
echo "<tr valign=\"top\">";
echo "<td align=right nowrap><p>";
print_string("changepassword", "auth");
echo ":</p></td>";
echo "<td>";
echo "<INPUT TYPE=\"text\" NAME=\"changepassword\" SIZE=40 VALUE=\"$config->changepassword\">";
echo "</td>";
echo "<td>";
print_string("changepasswordhelp","auth");
echo "</td></tr>";
}
echo "<tr valign=\"top\">";
echo "<td align=right nowrap><p>";
print_string("guestloginbutton", "auth");
echo ":</p></td>";
echo "<td>";
choose_from_menu($guestoptions, "guestloginbutton", $config->guestloginbutton, "");
echo "</td>";
echo "<td>";
print_string("showguestlogin","auth");
echo "</td></tr></table>";
echo "<CENTER><P><INPUT TYPE=\"submit\" VALUE=\"";
print_string("savechanges");
echo "\"></P></CENTER></FORM>";
print_simple_box_end();
print_footer();
exit;
/// Functions /////////////////////////////////////////////////////////////////
function validate_form(&$form, &$err) {
// if (empty($form->fullname))
// $err["fullname"] = get_string("missingsitename");
return;
}
?>
+197
View File
@@ -0,0 +1,197 @@
<FORM METHOD="post" action="config.php" NAME="form">
<TABLE cellpadding=9 cellspacing=0 >
<TR VALIGN=TOP>
<TD ALIGN=RIGHT><P>lang:</TD>
<TD>
<? choose_from_menu (get_list_of_languages(), "lang", $config->lang, "", "", "");
formerr($err["lang"]);
?>
</TD>
<TD>
<? print_string("configlang") ?>
</TD>
</TR>
<TR VALIGN=TOP>
<TD ALIGN=RIGHT><P>langdir:</TD>
<TD>
<? unset($options);
$options["LTR"] = get_string("langltr");
$options["RTL"] = get_string("langrtl");
choose_from_menu ($options, "langdir", $config->langdir, "", "", "");
?>
</TD>
<TD>
<? print_string("configlangdir") ?>
</TD>
</TR>
<TR VALIGN=TOP>
<TD ALIGN=RIGHT><P>locale:</TD>
<TD>
<INPUT NAME=locale TYPE=text SIZE=10 VALUE="<?=$config->locale?>">
<? formerr($err["locale"]); ?>
</TD>
<TD>
<? print_string("configlocale") ?>
</TD>
</TR>
<TR VALIGN=TOP>
<TD ALIGN=RIGHT><P>smtphosts:</TD>
<TD>
<INPUT NAME=smtphosts TYPE=text SIZE=30 VALUE="<?=$config->smtphosts?>">
<? formerr($err["smtphosts"]); ?>
</TD>
<TD>
<? print_string("configsmtphosts") ?>
</TD>
</TR>
<TR VALIGN=TOP>
<TD ALIGN=RIGHT><P>smtpuser:</TD>
<TD>
<INPUT NAME=smtpuser TYPE=text SIZE=10 VALUE="<?=$config->smtpuser?>">
<? formerr($err["smtpuser"]); ?>
</TD>
<TD ROWSPAN=2>
<? print_string("configsmtpuser") ?>
</TD>
</TR>
<TR VALIGN=TOP>
<TD ALIGN=RIGHT><P>smtppass:</TD>
<TD>
<INPUT NAME=smtppass TYPE=text SIZE=10 VALUE="<?=$config->smtppass?>">
<? formerr($err["smtppass"]); ?>
</TD>
</TR>
<TR VALIGN=TOP>
<TD ALIGN=RIGHT><P>gdversion:</TD>
<TD>
<? unset($options);
$options[0] = get_string("gdnot");
$options[1] = get_string("gd1");
$options[2] = get_string("gd2");
$installed = check_gd_version();
choose_from_menu ($options, "gdversion", $installed, "", "", "");
?>
</TD>
<TD>
<? print_string("configgdversion") ?>
</TD>
</TR>
<TR VALIGN=TOP>
<TD ALIGN=RIGHT><P>htmleditor:</TD>
<TD>
<? unset($options);
$options[0] = get_string("allownot");
$options[1] = get_string("allow");
choose_from_menu ($options, "htmleditor", $config->htmleditor, "", "", "");
formerr($err["htmleditor"]);
?>
</TD>
<TD>
<? print_string("confightmleditor") ?>
</TD>
</TR>
<TR VALIGN=TOP>
<TD ALIGN=RIGHT><P>maxeditingtime:</TD>
<TD>
<? $options[3600] = get_string("numminutes", "", 60);
$options[2700] = get_string("numminutes", "", 45);
$options[1800] = get_string("numminutes", "", 30);
$options[900] = get_string("numminutes", "", 15);
$options[300] = get_string("numminutes", "", 5);
$options[60] = get_string("numminutes", "", 1);
choose_from_menu ($options, "maxeditingtime", $config->maxeditingtime, "", "", "");
unset($options);
?>
</TD>
<TD>
<? print_string("configmaxeditingtime") ?>
</TD>
</TR>
<TR VALIGN=TOP>
<TD ALIGN=RIGHT><P>longtimenosee:</TD>
<TD>
<? $options[1000] = get_string("numdays", "", 1000);
$options[365] = get_string("numdays", "", 365);
$options[180] = get_string("numdays", "", 180);
$options[150] = get_string("numdays", "", 150);
$options[120] = get_string("numdays", "", 120);
$options[90] = get_string("numdays", "", 90);
$options[60] = get_string("numdays", "", 60);
$options[30] = get_string("numdays", "", 30);
$options[7] = get_string("numdays", "", 7);
choose_from_menu ($options, "longtimenosee", $config->longtimenosee, "", "", "");
unset($options);
?>
</TD>
<TD>
<? print_string("configlongtimenosee") ?>
</TD>
</TR>
<TR VALIGN=TOP>
<TD ALIGN=RIGHT><P>zip:</TD>
<TD>
<INPUT name=zip TYPE=text SIZE=30 VALUE="<?=$config->zip?>">
<? formerr($err["zip"]); ?>
</TD>
<TD>
<? print_string("configzip") ?>
</TD>
</TR>
<TR VALIGN=TOP>
<TD ALIGN=RIGHT><P>unzip:</TD>
<TD>
<INPUT name=unzip TYPE=text SIZE=30 VALUE="<?=$config->unzip?>">
<? formerr($err["unzip"]); ?>
</TD>
<TD>
<? print_string("configunzip") ?>
</TD>
</TR>
<TR VALIGN=TOP>
<TD ALIGN=RIGHT><P>slasharguments:</TD>
<TD>
<? $options[0] = "file.php?file=/pic.jpg";
$options[1] = "file.php/pic.jpg";
$installed = check_gd_version();
choose_from_menu ($options, "slasharguments", $config->slasharguments, "", "", "");
unset($options);
?>
</TD>
<TD>
<? print_string("configslasharguments") ?>
</TD>
</TR>
<TR VALIGN=TOP>
<TD ALIGN=RIGHT><P>proxyhost:</TD>
<TD>
<INPUT name=proxyhost TYPE=text SIZE=30 VALUE="<?=$config->proxyhost?>">
<? formerr($err["proxyhost"]); ?>
</TD>
<TD ROWSPAN=2>
<? print_string("configproxyhost") ?>
</TD>
</TR>
<TR VALIGN=TOP>
<TD ALIGN=RIGHT><P>proxyport:</TD>
<TD>
<INPUT name=proxyport TYPE=text SIZE=5 VALUE="<?=$config->proxyport?>">
<? formerr($err["proxyport"]); ?>
</TD>
</TR>
<TR>
<TD COLSPAN=3 ALIGN=CENTER>
<INPUT TYPE="submit" VALUE="<? print_string("savechanges") ?>"></TD>
</TR>
</TABLE>
</FORM>
+110
View File
@@ -0,0 +1,110 @@
<?PHP // $Id$
// config.php - allows admin to edit all configuration variables
include("../config.php");
if (isset($phpinfo)) { // For debugging purposes, protected by password
if (md5($phpinfo) == "caf9b6b99962bf5c2264824231d7a40c") {
if ($site = get_site()) {
print_heading("$site->fullname");
}
phpinfo();
exit;
}
}
if (isset($config)) { // For debugging purposes, protected by password
if (md5($config) == "caf9b6b99962bf5c2264824231d7a40c") {
if ($site = get_site()) {
print_heading("$site->fullname");
}
$TEMPCFG = $CFG;
unset($TEMPCFG->dbuser);
unset($TEMPCFG->dbpass);
print_object($TEMPCFG);
exit;
}
}
if ($site = get_site()) { // If false then this is a new installation
require_login();
if (!isadmin()) {
error("Only the admin can use this page");
}
}
/// If data submitted, then process and store.
if (match_referer() && isset($HTTP_POST_VARS)) {
$config = (object)$HTTP_POST_VARS;
validate_form($config, $err);
if (count($err) == 0) {
print_header();
foreach ($config as $name => $value) {
unset($conf);
$conf->name = $name;
$conf->value = $value;
if ($current = get_record("config", "name", $name)) {
$conf->id = $current->id;
if (! update_record("config", $conf)) {
notify("Could not update $name to $value");
}
} else {
if (! insert_record("config", $conf)) {
notify("Error: could not add new variable $name !");
}
}
}
redirect("index.php", get_string("changessaved"), 1);
exit;
} else {
foreach ($err as $key => $value) {
$focus = "form.$key";
}
}
}
/// Otherwise fill and print the form.
if (!isset($config)) {
$config = $CFG;
}
$stradmin = get_string("administration");
$strconfigvariables = get_string("configvariables");
if ($site) {
print_header("$site->shortname: $strconfigvariables", "$site->fullname",
"<A HREF=\"index.php\">$stradmin</A> -> $strconfigvariables", "$focus");
print_heading($strconfigvariables);
} else {
print_header();
print_heading($strconfigvariables);
print_simple_box(get_string("configintro"), "center");
echo "<BR>";
}
print_simple_box_start("center", "", "$THEME->cellheading");
include("config.html");
print_simple_box_end();
print_footer();
exit;
/// Functions /////////////////////////////////////////////////////////////////
function validate_form(&$form, &$err) {
// if (empty($form->fullname))
// $err["fullname"] = get_string("missingsitename");
return;
}
?>
+1 -5
View File
@@ -46,11 +46,7 @@
lastaccess < '$cutofftime' AND
u.id = s.user GROUP BY u.id")) {
foreach ($users as $user) {
if (delete_records("user_students", "user", $user->id)) {
// Delete other things ... this should be modular than it is right now:
delete_records("forum_subscriptions", "user", $user->id);
if (unenrol_student($user->id)) {
echo "Deleted student enrolment for $user->firstname $user->lastname ($user->id)\n";
}
}
+63
View File
@@ -0,0 +1,63 @@
<?PHP //$Id$
// Deletes the moodledata directory, COMPLETELY!!
// BE VERY CAREFUL USING THIS!
include("../config.php");
require_login();
if (!isadmin()) {
error("You must be admin to use this script!");
}
$deletedir = $CFG->dataroot; // The directory to delete!
if (!$sure) {
notice_yesno ("Are you completely sure you want to delete everything inside the directory $deletedir ?", "delete.php?sure=yes", "index.php");
exit;
}
if (!$reallysure) {
notice_yesno ("Are you REALLY REALLY completely sure you want to delete everything inside the directory $deletedir (this includes all user images, and any other course files that have been created) ?", "delete.php?sure=yes&reallysure=yes", "index.php");
exit;
}
/// OK, here goes ...
delete_subdirectories($deletedir);
echo "<H1 align=center>Done!</H1>";
print_continue($CFG->wwwroot);
exit;
function delete_subdirectories($rootdir) {
$dir = opendir($rootdir);
while ($file = readdir($dir)) {
if ($file != "." and $file != "..") {
$fullfile = "$rootdir/$file";
if (filetype($fullfile) == "dir") {
delete_subdirectories($fullfile);
echo "Deleting $fullfile ... ";
if (rmdir($fullfile)) {
echo "Done.<BR>";
} else {
echo "FAILED.<BR>";
}
} else {
echo "Deleting $fullfile ... ";
if (unlink("$fullfile")) {
echo "Done.<BR>";
} else {
echo "FAILED.<BR>";
}
}
}
}
closedir($dir);
}
?>
+42
View File
@@ -0,0 +1,42 @@
<?PHP // $Id$
require("../config.php");
/// Normally this file is never used.
///
/// It can be useful to jump-start a new moodle installation when
/// it is being installed into a database that already contains
/// some tables.
///
/// For this case you would call this script directly
///
/// Warning: this method ASSUMES that all existing tables with
/// have different names to any Moodle tables, so make sure
/// there aren't any Moodle-named tables in your database before
/// using this script. See lib/db/mysql.sql and mod/*/db/mysql.sql
if ($CFG->version) { // To avoid this being used on a working site.
echo "No need to use this";
} else {
$strdatabasesetup = get_string("databasesetup");
$strdatabasesuccess = get_string("databasesuccess");
print_header($strdatabasesetup, $strdatabasesetup, $strdatabasesetup);
if (file_exists("$CFG->libdir/db/$CFG->dbtype.sql")) {
$db->debug = true;
if (modify_database("$CFG->libdir/db/$CFG->dbtype.sql")) {
$db->debug = false;
notify($strdatabasesuccess);
} else {
$db->debug = false;
error("Error: Main databases NOT set up successfully");
}
} else {
error("Error: Your database ($CFG->dbtype) is not yet fully supported by Moodle.
See the lib/db directory.");
}
print_continue("index.php");
}
+93 -32
View File
@@ -3,11 +3,21 @@
require("../config.php");
/// Check that PHP is of a sufficient version
if ( ! check_php_version("4.1.0") ) {
$version = phpversion();
print_heading("Sorry, Moodle requires PHP 4.1.0 or later (currently using version $version)");
die;
}
/// Check that config.php has been edited
if ($CFG->wwwroot == "http://example.com/moodle") {
error("Moodle has not been configured yet. You need to to edit config.php first.");
}
// Check databases and modules and install as needed.
/// Check databases and modules and install as needed.
if (! $db->Metatables() ) {
if (!$agreelicence) {
@@ -43,25 +53,26 @@
die;
}
// Check version of Moodle code on disk compared with database
// and upgrade if possible.
/// Check version of Moodle code on disk compared with database
/// and upgrade if possible.
include_once("$CFG->dirroot/version.php"); # defines $version and upgrades
include_once("$CFG->dirroot/version.php"); # defines $version
include_once("$CFG->dirroot/lib/db/$CFG->dbtype.php"); # defines upgrades
if ($dversion = get_field("config", "value", "name", "version")) {
if ($version > $dversion) { // upgrade
$a->oldversion = $dversion;
if ($CFG->version) {
if ($version > $CFG->version) { // upgrade
$a->oldversion = $CFG->version;
$a->newversion = $version;
$strdatabasechecking = get_string("databasechecking", "", $a);
$strdatabasesuccess = get_string("databasesuccess");
print_header($strdatabaseupgrades, $strdatabaseupgrades, $strdatabaseupgrades);
print_header($strdatabasechecking, $strdatabasechecking, $strdatabasechecking);
notify($strdatabasechecking);
$db->debug=true;
if (upgrade_moodle($dversion)) {
if (main_upgrade($CFG->version)) {
$db->debug=false;
if (set_field("config", "value", "$version", "name", "version")) {
if (set_config("version", $version)) {
notify($strdatabasesuccess);
print_continue("$CFG->wwwroot");
print_continue("index.php");
die;
} else {
notify("Upgrade failed! (Could not update version in config table)");
@@ -70,22 +81,21 @@
$db->debug=false;
notify("Upgrade failed! See /version.php");
}
} else if ($version < $dversion) {
} else if ($version < $CFG->version) {
notify("WARNING!!! The code you are using is OLDER than the version that made these databases!");
}
} else {
$dversion->name = "version";
$dversion->value = $version;
$strdatabaseupgrades = get_string("databaseupgrades");
print_header($strdatabaseupgrades, $strdatabaseupgrades, $strdatabaseupgrades);
if (insert_record("config", $dversion)) {
notify("You are currently using Moodle version $version");
if (set_config("version", $version)) {
notify("You are currently using Moodle version $version (Release $release)");
print_continue("index.php");
die;
} else {
$db->debug=true;
if (upgrade_moodle(0)) {
if (main_upgrade(0)) {
print_continue("index.php");
} else {
error("A problem occurred inserting current version into databases");
@@ -94,10 +104,26 @@
}
}
/// Updated human-readable release version if necessary
// Find and check all modules and load them up or upgrade them if necessary
if ($release <> $CFG->release) { // Update the release version
$strdatabaseupgrades = get_string("databaseupgrades");
print_header($strdatabaseupgrades, $strdatabaseupgrades, $strdatabaseupgrades);
print_heading($release);
if (!set_config("release", $release)) {
notify("ERROR: Could not update release version in database!!");
}
print_continue("index.php");
print_simple_box_start("CENTER");
include("$CFG->dirroot/doc/release.html");
print_simple_box_end();
print_continue("index.php");
exit;
}
/// Find and check all modules and load them up or upgrade them if necessary
if (!$mods = get_list_of_plugins("mod") ) {
error("No modules installed!");
}
@@ -108,6 +134,7 @@
unset($module);
include_once("$fullmod/version.php"); # defines $module with version etc
include_once("$fullmod/db/$CFG->dbtype.php"); # defines upgrading function
if (!isset($module)) {
continue;
@@ -166,39 +193,73 @@
die;
}
// Set up the overall site name etc.
if (! $site = get_site()) {
redirect("$CFG->wwwroot/admin/site.php");
}
if (!isadmin()) {
if (! record_exists_sql("SELECT * FROM user_admins")) { // No admin user yet
redirect("$CFG->wwwroot/admin/user.php");
/// Insert default values for any important configuration variables
include_once("$CFG->dirroot/lib/defaults.php");
$CFG = (array)$CFG;
foreach ($defaults as $name => $value) {
if (!isset($CFG[$name])) {
$config->name = $name;
$config->value = $CFG[$name] = $value;
insert_record("config", $config);
$configchange = true;
}
error("You need to be an admin user to use this page.", "$CFG->wwwroot/login/");
}
$CFG = (object)$CFG;
/// If any new configurations were found then send to the config page to check
if ($configchange) {
redirect("config.php");
}
/// Set up the overall site name etc.
if (! $site = get_site()) {
redirect("site.php");
}
/// Set up the admin user
if (! record_exists_sql("SELECT * FROM user_admins")) { // No admin user yet
redirect("user.php");
}
/// Check for valid admin user
if (!isadmin()) {
error("You need to be an admin user to use this page.", "$CFG->wwwroot/login/index.php");
}
// At this point, the databases exist, and the user is an admin
/// At this point everything is set up and the user is an admin, so print menu
$stradministration = get_string("administration");
print_header("$site->fullname: $stradministration","$site->fullname: $stradministration", "$stradministration");
print_header("$site->shortname: $stradministration","$site->fullname: $stradministration", "$stradministration");
$table->head = array (get_string("site"), get_string("courses"), get_string("users"));
$table->align = array ("CENTER", "CENTER", "CENTER");
$table->data[0][0] = "<P><A HREF=\"site.php\">".get_string("sitesettings")."</A></P>".
$table->data[0][0] = "<P><A HREF=\"config.php\">".get_string("configvariables")."</A></P>".
"<P><A HREF=\"site.php\">".get_string("sitesettings")."</A></P>".
"<P><A HREF=\"../course/log.php?id=$site->id\">".get_string("sitelogs")."</A></P>".
"<P><A HREF=\"../theme/index.php\">".get_string("choosetheme")."</A></P>".
"<P><A HREF=\"lang.php\">".get_string("checklanguage")."</A></P>";
if (file_exists("$CFG->dirroot/admin/$CFG->dbtype")) {
$table->data[0][0] .= "<P><A HREF=\"$CFG->dbtype/\">".get_string("managedatabase")."</A></P>";
}
$table->data[0][1] = "<P><A HREF=\"../course/edit.php\">".get_string("addnewcourse")."</A></P>".
"<P><A HREF=\"../course/teacher.php\">".get_string("assignteachers")."</A></P>".
"<P><A HREF=\"../course/delete.php\">".get_string("deletecourse")."</A></P>";
"<P><A HREF=\"../course/delete.php\">".get_string("deletecourse")."</A></P>".
"<P><A HREF=\"../course/categories.php\">".get_string("categories")."</A></P>";
$table->data[0][2] = "<P><A HREF=\"user.php?newuser=true\">".get_string("addnewuser")."</A></P>".
"<P><A HREF=\"user.php\">".get_string("edituser")."</A></P>";
"<P><A HREF=\"user.php\">".get_string("edituser")."</A></P>".
"<P><A HREF=\"auth.php\">".get_string("authentication")."</A></P>";
print_table($table);
print_footer();
print_heading("Moodle $CFG->release ($CFG->version)", "CENTER", 1);
print_footer($site);
?>
+238 -66
View File
@@ -1,6 +1,8 @@
<?PHP // $Id$
require("../config.php");
require("../config.php");
optional_variable($mode, "");
require_login();
@@ -14,88 +16,258 @@
$stradministration = get_string("administration");
$strchecklanguage = get_string("checklanguage");
$strcurrentlanguage = get_string("currentlanguage");
$strmissingstrings = get_string("missingstrings");
$strcomparelanguage = get_string("comparelanguage");
$strthislanguage = get_string("thislanguage");
print_header("$site->fullname", "$site->fullname",
"<A HREF=\"index.php\">$stradministration</A>
-> $strchecklanguage -> $CFG->lang");
switch ($mode) {
case "missing":
$navigation = "<A HREF=\"lang.php\">$strchecklanguage</A> -> $strmissingstrings";
$title = $strmissingstrings;
break;
case "compare":
$navigation = "<A HREF=\"lang.php\">$strchecklanguage</A> -> $strcomparelanguage";
$title = $strcomparelanguage;
break;
default:
$title = $strchecklanguage;
$navigation = $strchecklanguage;
break;
}
if ($USER->lang) {
$currentlang = $USER->lang;
} else {
$currentlang = $CFG->lang;
}
// Get a list of all the files in the English directory
print_header("$site->shortname: $title", "$site->fullname",
"<A HREF=\"index.php\">$stradministration</A> -> $navigation");
if (! $files = get_directory_list("$CFG->dirroot/lang/en", "CVS")) {
if (!$mode) {
print_heading("$strcurrentlanguage: $currentlang - ".get_string("thislanguage"));
print_heading("<A HREF=\"lang.php?mode=missing\">$strmissingstrings</A>");
print_heading("<A HREF=\"lang.php?mode=compare\">$strcomparelanguage</A>");
print_footer();
exit;
}
// Get a list of all the root files in the English directory
$langdir = "$CFG->dirroot/lang/$currentlang";
$enlangdir = "$CFG->dirroot/lang/en";
if (! $stringfiles = get_directory_list($enlangdir, "", false)) {
error("Could not find English language pack!");
}
// For each file, check that a counterpart exists, then check all the strings
$langdir = "$CFG->dirroot/lang/$CFG->lang";
$enlangdir = "$CFG->dirroot/lang/en";
$dir = opendir($enlangdir);
while ($file = readdir($dir)) {
if ($file == "." or $file == ".." or $file == "CVS" or $file == "README" or $file == "help" or $file == "docs") {
continue;
foreach ($stringfiles as $key => $file) {
if ($file == "README" or $file == "help" or $file == "docs") {
unset($stringfiles[$key]);
}
}
if (!file_exists("$langdir/$file")) {
echo "<P><FONT COLOR=red>".get_string("filemissing", "", "$langdir/$file")."</FONT></P>";
continue;
}
unset($string);
include("$enlangdir/$file");
$enstring = $string;
unset($string);
include("$langdir/$file");
$first = true;
foreach ($enstring as $key => $value) {
if (!isset($string[$key])) {
$value = htmlentities($value);
$value = str_replace("$"."a", "\\$"."a", $value);
if ($first) {
echo "</PRE><HR><P><B>".get_string("stringsnotset","","$langdir/$file")."</B></P><PRE>";
$first = false;
$somethingfound = true;
if ($mode == "missing") {
// For each file, check that a counterpart exists, then check all the strings
foreach ($stringfiles as $file) {
if (!file_exists("$langdir/$file")) {
echo "<P><FONT COLOR=red>".get_string("filemissing", "", "$langdir/$file")."</FONT></P>";
continue;
}
unset($string);
include("$enlangdir/$file");
$enstring = $string;
unset($string);
include("$langdir/$file");
$first = true;
foreach ($enstring as $key => $value) {
if (!isset($string[$key])) {
$value = htmlspecialchars($value);
$value = str_replace("$"."a", "\\$"."a", $value);
if ($first) {
echo "</PRE><HR><P><B>".get_string("stringsnotset","","$langdir/$file")."</B></P><PRE>";
$first = false;
$somethingfound = true;
}
echo "$"."string[$key] = \"$value\";<BR>";
}
echo "$"."string[$key] = \"$value\";<BR>";
}
}
}
closedir($dir);
if (! $files = get_directory_list("$CFG->dirroot/lang/en/help", "CVS")) {
error("Could not find English language help files!");
}
foreach ($files as $filekey => $file) { // check all the help files.
if (!file_exists("$langdir/help/$file")) {
echo "<P><FONT COLOR=red>".get_string("filemissing", "", "$langdir/help/$file")."</FONT></P>";
$somethingfound = true;
continue;
if (! $files = get_directory_list("$CFG->dirroot/lang/en/help", "CVS")) {
error("Could not find English language help files!");
}
}
if (! $files = get_directory_list("$CFG->dirroot/lang/en/docs", "CVS")) {
error("Could not find English language docs files!");
}
foreach ($files as $filekey => $file) { // check all the docs files.
if (!file_exists("$langdir/docs/$file")) {
echo "<P><FONT COLOR=red>".get_string("filemissing", "", "$langdir/docs/$file")."</FONT></P>";
$somethingfound = true;
continue;
foreach ($files as $filekey => $file) { // check all the help files.
if (!file_exists("$langdir/help/$file")) {
echo "<P><FONT COLOR=red>".get_string("filemissing", "", "$langdir/help/$file")."</FONT></P>";
$somethingfound = true;
continue;
}
}
if (! $files = get_directory_list("$CFG->dirroot/lang/en/docs", "CVS")) {
error("Could not find English language docs files!");
}
foreach ($files as $filekey => $file) { // check all the docs files.
if (!file_exists("$langdir/docs/$file")) {
echo "<P><FONT COLOR=red>".get_string("filemissing", "", "$langdir/docs/$file")."</FONT></P>";
$somethingfound = true;
continue;
}
}
if ($somethingfound) {
print_continue("lang.php");
} else {
notice(get_string("languagegood"), "lang.php");
}
}
if (!$somethingfound) {
notice(get_string("languagegood"), "index.php");
} else {
print_continue("index.php");
} else if ($mode == "compare") {
if (isset($HTTP_POST_VARS['file'])){ // Save a file
$newstrings = $HTTP_POST_VARS;
$file = $newstrings['file'];
unset($newstrings['file']);
if (lang_save_file($langdir, $file, $newstrings)) {
notify(get_string("changessaved")." ($langdir/$file)");
} else {
error("Could not save the file '$file'!", "lang.php?mode=compare");
}
}
print_heading($strcomparelanguage);
echo "<CENTER>";
helpbutton("langedit",$strcomparelanguage);
echo "</CENTER>";
foreach ($stringfiles as $file) {
print_heading("$file", "LEFT", 4);
if (!file_exists("$langdir/$file")) {
echo "<P><FONT COLOR=red>".get_string("filemissing", "", "$langdir/$file")."</FONT></P>";
continue;
}
error_reporting(0);
if ($f = fopen("$langdir/$file","r+")) {
$editable = true;
fclose($f);
} else {
$editable = false;
echo "<P><FONT SIZE=1>".get_string("makeeditable", "", "$langdir/$file")."</FONT></P>";
}
error_reporting(7);
unset($string);
include("$enlangdir/$file");
$enstring = $string;
ksort($enstring);
unset($string);
include("$langdir/$file");
if ($editable) {
echo "<FORM NAME=\"$file\" ACTION=\"lang.php\" METHOD=\"POST\">";
}
echo "<TABLE WIDTH=\"100%\" CELLPADDING=2 CELLSPACING=3 BORDER=0>";
foreach ($enstring as $key => $envalue) {
$envalue = nl2br(htmlspecialchars($envalue));
$envalue = str_replace("\$a","<B>\$a</B>", $envalue); // Make variables bold
// TODO: It would be nice if all the $a->something variables were bold too
echo "<TR>";
echo "<TD WIDTH=20% BGCOLOR=\"$THEME->cellheading\" NOWRAP VALIGN=TOP>$key</TD>";
echo "<TD WIDTH=40% BGCOLOR=\"$THEME->cellheading\" VALIGN=TOP>$envalue</TD>";
$value = str_replace("\\","",$string[$key]); // Delete all slashes
$value = htmlspecialchars($value);
if ($editable) {
echo "<TD WIDTH=40% VALIGN=TOP>";
if (isset($string[$key])) {
$valuelen = strlen($value);
} else {
$valuelen = strlen($envalue);
}
$cols=50;
if (strstr($value, "\r") or strstr($value, "\n") or $valuelen > $cols) {
$rows = ceil($valuelen / $cols);
echo "<TEXTAREA NAME=\"string-$key\" cols=\"$cols\" rows=\"$rows\">$value</TEXTAREA>";
} else {
$cols = $valuelen + 2;
echo "<INPUT TYPE=\"TEXT\" NAME=\"string-$key\" VALUE=\"$value\" SIZE=\"$cols\"></TD>";
}
echo "</TD>";
} else {
if (isset($string[$key])) {
echo "<TD WIDTH=40% BGCOLOR=white VALIGN=TOP>$value</TD>";
} else {
echo "<TD WIDTH=40% BGCOLOR=white ALIGN=CENTER VALIGN=TOP>-</TD>";
}
}
}
if ($editable) {
echo "<TR><TD COLSPAN=2>&nbsp;<TD>";
echo " <INPUT TYPE=\"hidden\" NAME=\"file\" VALUE=\"$file\">";
echo " <INPUT TYPE=\"hidden\" NAME=\"mode\" VALUE=\"compare\">";
echo " <INPUT TYPE=\"submit\" NAME=\"update\" VALUE=\"".get_string("savechanges").": $file\">";
echo "</TD></TR>";
}
echo "</TABLE>";
echo "</FORM>";
}
print_continue("lang.php");
}
print_footer();
//////////////////////////////////////////////////////////////////////
function lang_save_file($path, $file, $strings) {
// Thanks to Petri Asikainen for the original version of code
// used to save language files.
//
// $path is a full pathname to the file
// $file is the file to overwrite.
// $strings is an array of strings to write
global $CFG;
error_reporting(0);
if (!$f = fopen("$path/$file","w")) {
return false;
}
error_reporting(7);
fwrite($f, "<?PHP // \$Id\$ \n");
fwrite($f, " // $file - created with Moodle $CFG->release ($CFG->version)\n\n\n");
ksort($strings);
foreach ($strings as $key => $value) {
list($id, $stringname) = explode("-",$key);
$value = str_replace("\\","",$value); // Delete all slashes
$value = str_replace("$"."a", "\\$"."a", $value); // Add slashes for $a
$value = str_replace("\"", "\\\"", $value); // Add slashes for "
if ($id == "string"){
fwrite($f,"\$string['$stringname'] = \"$value\";\n");
}
}
fwrite($f,"\n?>\n");
fclose($f);
return true;
}
?>
+7 -7
View File
@@ -23,17 +23,17 @@
if ($form->id) {
if (update_record("course", $form)) {
redirect("$CFG->wwwroot/admin/index.php", "Changes saved");
redirect("index.php", get_string("changessaved"));
} else {
error("Serious Error! Could not update the site record! (id = $form->id)");
}
} else {
if ($newid = insert_record("course", $form)) {
$cat->name = "General";
$cat->name = get_string("miscellaneous");
if (insert_record("course_categories", $cat)) {
redirect("$CFG->wwwroot/admin/index.php", "Changes saved", "1");
redirect("index.php", get_string("changessaved"), "1");
} else {
error("Serious Error! Could not set up the default categories!");
error("Serious Error! Could not set up a default course category!");
}
} else {
error("Serious Error! Could not set up the site!");
@@ -61,11 +61,11 @@
$stradmin = get_string("administration");
$strsitesettings = get_string("sitesettings");
print_header("$site->fullname", "$site->fullname",
"<A HREF=\"$CFG->wwwroot/admin/\">$stradmin</A> -> $strsitesettings", "$focus");
print_header("$site->shortname: $strsitesettings", "$site->fullname",
"<A HREF=\"index.php\">$stradmin</A> -> $strsitesettings", "$focus");
print_simple_box_start("center", "", "$THEME->cellheading");
print_heading($strsitesettings);
print_simple_box_start("center", "", "$THEME->cellheading");
include("site.html");
print_simple_box_end();
print_footer();
+146 -16
View File
@@ -4,6 +4,15 @@
require("../user/lib.php");
require("../lib/countries.php");
$recordsperpage = 30;
optional_variable($newuser, "");
optional_variable($delete, "");
optional_variable($confirm, "");
optional_variable($sort, "name");
optional_variable($dir, "ASC");
optional_variable($page, 0);
if (! record_exists_sql("SELECT * FROM user_admins")) { // No admin user yet
$user->firstname = "Admin";
$user->lastname = "User";
@@ -11,6 +20,7 @@
$user->password = md5("admin");
$user->email = "root@localhost";
$user->confirmed = 1;
$user->lang = $CFG->lang;
$user->maildisplay = 1;
$user->timemodified = time();
@@ -61,12 +71,12 @@
}
if ($newuser) { // Create a new user
$user->firstname = "";
$user->lastname = "";
$user->username = "changeme";
$user->password = "";
$user->email = "";
$user->lang = $CFG->lang;
$user->confirmed = 1;
$user->timemodified = time();
@@ -80,26 +90,146 @@
} else { // List all users for editing
if ($users = get_records_sql("SELECT * from user WHERE username <> 'guest' ORDER BY firstname")) {
$stredituser = get_string("edituser");
$stradministration = get_string("administration");
$stredit = get_string("edit");
$strdelete = get_string("delete");
$stredituser = get_string("edituser");
$stradministration = get_string("administration");
$stredit = get_string("edit");
$strdelete = get_string("delete");
$strdeletecheck = get_string("deletecheck");
print_header("$site->fullname : $stredituser", $site->fullname,
"<A HREF=\"$CFG->wwwroot/admin\">$stradministration</A> -> $stredituser");
print_header("$site->shortname: $stredituser", $site->fullname,
"<A HREF=\"index.php\">$stradministration</A> -> $stredituser");
print_heading(get_string("chooseuser"));
if ($delete) { // Delete a selected user, after confirmation
if (!$user = get_record("user", "id", "$delete")) {
error("No such user!");
}
if ($confirm != md5($delete)) {
notice_yesno(get_string("deletecheckfull", "", "'$user->firstname $user->lastname'"),
"user.php?delete=$delete&confirm=".md5($delete), "user.php");
$table->head = array (get_string("fullname"), get_string("email"), get_string("city"),
get_string("country"), " ");
$table->align = array ("LEFT", "LEFT", "CENTER", "CENTER", "CENTER", "CENTER");
exit;
} else if (!$user->deleted) {
$user->deleted = "1";
$user->username = "$user->email.".time(); // Remember it just in case
$user->email = ""; // Clear this field to free it up
$user->timemodified = time();
if (update_record("user", $user)) {
unenrol_student($user->id); // From all courses
remove_teacher($user->id); // From all courses
remove_admin($user->id);
notify(get_string("deletedactivity", "", "$user->firstname $user->lastname"));
} else {
notify(get_string("deletednot", "", "$user->firstname $user->lastname"));
}
}
}
// Carry on with the user listing
if (!$user = get_record_sql("SELECT count(*) as count FROM user WHERE username <> 'guest' AND deleted <> '1'")) {
error("Could not search for users?");
}
$usercount = $user->count;
$columns = array("name", "email", "city", "country", "lastaccess");
foreach ($columns as $column) {
$string[$column] = get_string("$column");
$columnsort = "$column";
if ($column == "lastaccess") {
$columndir = "DESC";
} else {
$columndir = "ASC";
}
if ($columnsort == $sort) {
$$column = $string[$column];
} else {
$$column = "<A HREF=\"user.php?sort=$columnsort&dir=$columndir\">".$string[$column]."</A>";
}
}
if ($sort == "name") {
$sort = "firstname";
}
if ($users = get_records_sql("SELECT id, username, email, firstname, lastname, city, country, lastaccess from user WHERE username <> 'guest'
AND deleted <> '1' ORDER BY $sort $dir LIMIT $page,$recordsperpage")) {
print_heading("$usercount ".get_string("users"));
$a->start = $page;
$a->end = $page + $recordsperpage;
if ($a->end > $usercount) {
$a->end = $usercount;
}
echo "<TABLE align=center cellpadding=10><TR>";
echo "<TD>";
if ($page) {
$prevpage = $page - $recordsperpage;
if ($prevpage < 0) {
$prevpage = 0;
}
$options["dir"] = $dir;
$options["page"] = 0;
$options["sort"] = $sort;
print_single_button("user.php", $options, " << ");
echo "</TD><TD>";
$options["page"] = $prevpage;
print_single_button("user.php", $options, " < ");
}
echo "</TD><TD>";
print_heading(get_string("displayingusers", "", $a));
echo "</TD><TD>";
$nextpage = $page + $recordsperpage;
if ($nextpage < $usercount) {
$options["dir"] = $dir;
$options["page"] = $nextpage;
$options["sort"] = $sort;
print_single_button("user.php", $options, " > ");
echo "</TD><TD>";
$options["page"] = $usercount-$recordsperpage;
print_single_button("user.php", $options, " >> ");
}
echo "</TD></TR></TABLE>";
flush();
foreach ($users as $key => $user) {
$users[$key]->country = $COUNTRIES[$user->country];
}
if ($sort == "country") { // Need to resort by full country name, not code
foreach ($users as $user) {
$susers[$user->id] = $user->country;
}
asort($susers);
foreach ($susers as $key => $value) {
$nusers[] = $users[$key];
}
$users = $nusers;
}
$table->head = array ($name, $email, $city, $country, $lastaccess, "", "");
$table->align = array ("LEFT", "LEFT", "LEFT", "LEFT", "LEFT", "CENTER", "CENTER");
$table->width = "95%";
foreach ($users as $user) {
if ($user->id == $USER->id or $user->username == "changeme") {
$deletebutton = "";
} else {
$deletebutton = "<A HREF=\"user.php?delete=$user->id\" TARGET=\"$strdeletecheck\">$strdelete</A>";
}
if ($user->lastaccess) {
$strlastaccess = format_time(time() - $user->lastaccess);
} else {
$strlastaccess = get_string("never");
}
$table->data[] = array ("<A HREF=\"../user/view.php?id=$user->id&course=$site->id\">$user->firstname $user->lastname</A>",
"$user->email",
"$user->city",
$COUNTRIES[$user->country],
"<A HREF=\"../user/edit.php?id=$user->id&course=$site->id\">$stredit</A>");
"$user->email",
"$user->city",
"$user->country",
$strlastaccess,
"<A HREF=\"../user/edit.php?id=$user->id&course=$site->id\">$stredit</A>",
$deletebutton);
}
print_table($table);
+79
View File
@@ -0,0 +1,79 @@
This directory contains authentication modules.
Each of these modules describes a different way to
check that a user has provided a correct
- username, and
- password.
Even when external forms of authentication are being
used, Moodle still maintains the internal "user" table
with all the associated information about that user such
as name, email address and so on.
The active method is set by the admin on the Configuration page.
email - authentication by email (DEFAULT METHOD)
- user fills out form with email address
- email sent to user with link
- user clicks on link in email to confirm
- user account is created
- user can log in
none - no authentication at all .. very insecure!!
- user logs in using ANY username and password
- if the username doesn't already exist then
a new account is created
- when user tries to access a course they
are forced to set up their account details
ldap - Uses an external LDAP server
- user logs in using username and password
- these are checked against an LDAP server
- if correct, user is logged in
- optionally, info is copied from the LDAP
database to the Moodle user database
(see the ldap/README for more details on config etc...)
imap - Uses an external IMAP server
- user logs in using username and password
- these are checked against an IMAP server
- if correct, user is logged in
- if the username doesn't already exist then
a new account is created
pop3 - Uses an external POP3 server
- user logs in using username and password
- these are checked against a POP3 server
- if correct, user is logged in
- if the username doesn't already exist then
a new account is created
nntp - Uses an external NNTP server
- user logs in using username and password
- these are checked against an NNTP server
- if correct, user is logged in
- if the username doesn't already exist then
a new account is created
db - Uses an external database to check username/password
- user logs in using username and password
- these are checked against an external database
- if correct, user is logged in
- if the username doesn't already exist then
a new Moodle account is created
+191
View File
@@ -0,0 +1,191 @@
<tr valign="top" BGCOLOR="<?=$THEME->cellheading2 ?>">
<TD ALIGN=RIGHT><P>auth_dbhost:</TD>
<TD>
<INPUT name=auth_dbhost TYPE=text SIZE=30 VALUE="<?=$config->auth_dbhost?>">
<? formerr($err["auth_dbhost"]); ?>
</TD>
<TD>
<? print_string("auth_dbhost","auth") ?>
</TD>
</TR>
<TR VALIGN=TOP BGCOLOR="<?=$THEME->cellheading2 ?>">
<TD ALIGN=RIGHT><P>auth_dbtype:</TD>
<TD>
<? $dbtypes = array("access","ado_access", "ado", "ado_mssql", "borland_ibase", "csv", "db2", "fbsql", "firebird", "ibase", "informix72", "informix", "mssql", "mysql", "mysqlt", "oci805", "oci8", "oci8po", "odbc", "odbc_mssql", "odbc_oracle", "oracle", "postgres64", "postgres7", "postgres", "proxy", "sqlanywhere", "sybase", "vfp");
foreach ($dbtypes as $dbtype) {
$dboptions[$dbtype] = $dbtype;
}
choose_from_menu($dboptions, "auth_dbtype", $config->auth_dbtype, "");
?>
</TD>
<TD>
<? print_string("auth_dbtype","auth") ?>
</TD>
</TR>
<TR VALIGN=TOP BGCOLOR="<?=$THEME->cellheading2 ?>">
<TD ALIGN=RIGHT><P>auth_dbname:</TD>
<TD>
<INPUT name=auth_dbname TYPE=text SIZE=30 VALUE="<?=$config->auth_dbname?>">
<? formerr($err["auth_dbname"]); ?>
</TD>
<TD>
<? print_string("auth_dbname","auth") ?>
</TD>
</TR>
<TR VALIGN=TOP BGCOLOR="<?=$THEME->cellheading2 ?>">
<TD ALIGN=RIGHT><P>auth_dbuser:</TD>
<TD>
<INPUT name=auth_dbuser TYPE=text SIZE=30 VALUE="<?=$config->auth_dbuser?>">
<? formerr($err["auth_dbuser"]); ?>
</TD>
<TD>
<? print_string("auth_dbuser","auth") ?>
</TD>
</TR>
<TR VALIGN=TOP BGCOLOR="<?=$THEME->cellheading2 ?>">
<TD ALIGN=RIGHT><P>auth_dbpass:</TD>
<TD>
<INPUT name="auth_dbpass" TYPE="text" SIZE="30" VALUE="<?=$config->auth_dbpass?>">
<? formerr($err["auth_dbpass"]); ?>
</TD>
<TD>
<? print_string("auth_dbpass","auth") ?>
</TD>
</TR>
<TR VALIGN=TOP BGCOLOR="<?=$THEME->cellheading2 ?>">
<TD ALIGN=RIGHT><P>auth_dbtable:</TD>
<TD>
<INPUT name="auth_dbtable" TYPE="text" SIZE="30" VALUE="<?=$config->auth_dbtable?>">
<? formerr($err["auth_dbtable"]); ?>
</TD>
<TD>
<? print_string("auth_dbtable","auth") ?>
</TD>
</TR>
<TR VALIGN=TOP BGCOLOR="<?=$THEME->cellheading2 ?>">
<TD ALIGN=RIGHT><P>auth_dbfielduser:</TD>
<TD>
<INPUT name="auth_dbfielduser" TYPE="text" SIZE="30" VALUE="<?=$config->auth_dbfielduser?>">
<? formerr($err["auth_dbfielduser"]); ?>
</TD>
<TD>
<? print_string("auth_dbfielduser","auth") ?>
</TD>
</TR>
<TR VALIGN=TOP BGCOLOR="<?=$THEME->cellheading2 ?>">
<TD ALIGN=RIGHT><P>auth_dbfieldpass:</TD>
<TD>
<INPUT name="auth_dbfieldpass" TYPE="text" SIZE="30" VALUE="<?=$config->auth_dbfieldpass?>">
<? formerr($err["auth_dbfieldpass"]); ?>
</TD>
<TD>
<? print_string("auth_dbfieldpass","auth") ?>
</TD>
</TR>
<TR>
<TD ALIGN=RIGHT><P><? print_string("firstname") ?>:</TD>
<TD>
<INPUT name="auth_user_firstname" TYPE="text" SIZE="30" VALUE="<?=$config->auth_user_firstname?>">
</TD>
<TD rowspan=12 VALIGN=CENTER>
<? print_string("auth_dbextrafields","auth") ?>
</TD>
</TR>
<TR VALIGN=TOP>
<TD ALIGN=RIGHT><P><? print_string("lastname") ?>:</TD>
<TD>
<INPUT name="auth_user_lastname" TYPE="text" SIZE="30" VALUE="<?=$config->auth_user_lastname?>">
</TD>
</TR>
<TR VALIGN=TOP>
<TD ALIGN=RIGHT><P><? print_string("email") ?>:</TD>
<TD>
<INPUT name="auth_user_email" TYPE="text" SIZE="30" VALUE="<?=$config->auth_user_email?>">
</TD>
</TR>
<TR VALIGN=TOP>
<TD ALIGN=RIGHT><P><? print_string("phone") ?> 1:</TD>
<TD>
<INPUT name="auth_user_phone1" TYPE="text" SIZE="30" VALUE="<?=$config->auth_user_phone1?>">
</TD>
</TR>
<TR VALIGN=TOP>
<TD ALIGN=RIGHT><P><? print_string("phone") ?> 2:</TD>
<TD>
<INPUT name="auth_user_phone2" TYPE="text" SIZE="30" VALUE="<?=$config->auth_user_phone2?>">
</TD>
</TR>
<TR VALIGN=TOP>
<TD ALIGN=RIGHT><P><? print_string("department") ?>:</TD>
<TD>
<INPUT name="auth_user_department" TYPE="text" SIZE="30" VALUE="<?=$config->auth_user_department?>">
</TD>
</TR>
<TR VALIGN=TOP>
<TD ALIGN=RIGHT><P><? print_string("address") ?>:</TD>
<TD>
<INPUT name="auth_user_address" TYPE="text" SIZE="30" VALUE="<?=$config->auth_user_address?>">
</TD>
</TR>
<TR VALIGN=TOP>
<TD ALIGN=RIGHT><P><? print_string("city") ?>:</TD>
<TD>
<INPUT name="auth_user_city" TYPE="text" SIZE="30" VALUE="<?=$config->auth_user_city?>">
</TD>
</TR>
<TR VALIGN=TOP>
<TD ALIGN=RIGHT><P><? print_string("country") ?>:</TD>
<TD>
<INPUT name="auth_user_country" TYPE="text" SIZE="30" VALUE="<?=$config->auth_user_country?>">
</TD>
</TR>
<TR VALIGN=TOP>
<TD ALIGN=RIGHT><P><? print_string("description") ?>:</TD>
<TD>
<INPUT name="auth_user_description" TYPE="text" SIZE="30" VALUE="<?=$config->auth_user_description?>">
</TD>
</TR>
<TR VALIGN=TOP>
<TD ALIGN=RIGHT><P><? print_string("idnumber") ?>:</TD>
<TD>
<INPUT name="auth_user_idnumber" TYPE="text" SIZE="30" VALUE="<?=$config->auth_user_idnumber?>">
</TD>
</TR>
<TR VALIGN=TOP>
<TD ALIGN=RIGHT><P><? print_string("language") ?>:</TD>
<TD>
<INPUT name="auth_user_lang" TYPE="text" SIZE="30" VALUE="<?=$config->auth_user_lang?>">
</TD>
</TR>
<TR VALIGN=TOP>
<TD ALIGN=RIGHT><P><? print_string("instructions", "auth") ?>:</TD>
<TD>
<TEXTAREA NAME=auth_instructions COLS=30 ROWS=10 WRAP=virtual><? p($config->auth_instructions) ?></TEXTAREA>
</TD>
<TD>
<? print_string("authinstructions","auth") ?>
<? helpbutton("text", get_string("helptext")) ?>
</TD>
</TR>
+66
View File
@@ -0,0 +1,66 @@
<?PHP // $Id$
// Authentication by looking up an external database table
// This code is completely untested so far - IT NEEDS TESTERS!
// Looks like it should work though ...
function auth_user_login ($username, $password) {
// Returns true if the username and password work
// and false if they are wrong or don't exist.
global $CFG;
ADOLoadCode($CFG->auth_dbtype);
$authdb = &ADONewConnection();
$authdb->PConnect($CFG->auth_dbhost,$CFG->auth_dbuser,$CFG->auth_dbpass,$CFG->auth_dbname);
$rs = $authdb->Execute("SELECT * FROM $CFG->auth_dbtable
WHERE $CFG->auth_dbfielduser = '$username'
AND $CFG->auth_dbfieldpass = '$password' ");
if (!$rs) {
notify("Could not connect to the specified authentication database...");
return false;
}
if ( $rs->RecordCount() ) {
return true;
} else {
return false;
}
}
function auth_get_userinfo($username){
// Reads any other information for a user from external database,
// then returns it in an array
global $CFG;
$config = (array) $CFG;
ADOLoadCode($CFG->auth_dbtype);
$authdb = &ADONewConnection();
$authdb->PConnect($CFG->auth_dbhost,$CFG->auth_dbuser,$CFG->auth_dbpass,$CFG->auth_dbname);
$fields = array("firstname", "lastname", "email", "phone1", "phone2",
"department", "address", "city", "country", "description",
"idnumber", "lang");
$result = array();
foreach ($fields as $field) {
if ($config["auth_user_$field"]) {
if ($rs = $authdb->Execute("SELECT ".$config["auth_user_$field"]." FROM $CFG->auth_dbtable
WHERE $CFG->auth_dbfielduser = '$username'")) {
if ( $rs->RecordCount() == 1 ) {
$result["$field"] = $rs->fields[$config["auth_user_$field"]];
}
}
}
}
return $result;
}
?>
+1
View File
@@ -0,0 +1 @@
<!-- No config needed -->
+19
View File
@@ -0,0 +1,19 @@
<?PHP // $Id$
// Standard authentication function
function auth_user_login ($username, $password) {
// Returns true if the username and password work
// and false if they don't
global $CFG;
if (! $user = get_user_info_from_db("username", $username)) {
return false;
}
return ($user->password == md5($password));
}
?>
+47
View File
@@ -0,0 +1,47 @@
<tr valign="top" BGCOLOR="<?=$THEME->cellheading2 ?>">
<TD ALIGN=RIGHT><P>auth_imaphost:</TD>
<TD>
<INPUT name=auth_imaphost TYPE=text SIZE=30 VALUE="<?=$config->auth_imaphost?>">
<? formerr($err["ldap_host_url"]); ?>
</TD>
<TD>
<? print_string("auth_imaphost","auth") ?>
</TD>
</TR>
<TR VALIGN=TOP BGCOLOR="<?=$THEME->cellheading2 ?>">
<TD ALIGN=RIGHT><P>auth_imaptype:</TD>
<TD>
<? $imaptypes = array("imap","imapssl", "imapcert", "imaptls");
foreach($imaptypes as $imaptype) {
$imapoptions[$imaptype] = $imaptype;
}
choose_from_menu($imapoptions, "auth_imaptype", $config->auth_imaptype, "");
?>
</TD>
<TD>
<? print_string("auth_imaptype","auth") ?>
</TD>
</TR>
<TR VALIGN=TOP BGCOLOR="<?=$THEME->cellheading2 ?>">
<TD ALIGN=RIGHT><P>auth_imapport:</TD>
<TD>
<INPUT name=auth_imapport TYPE=text SIZE=6 VALUE="<?=$config->auth_imapport?>">
<? formerr($err["auth_imapport"]); ?>
</TD>
<TD>
<? print_string("auth_imapport","auth") ?>
</TD>
</TR>
<TR VALIGN=TOP>
<TD ALIGN=RIGHT><P><? print_string("instructions", "auth") ?>:</TD>
<TD>
<TEXTAREA NAME=auth_instructions COLS=30 ROWS=10 WRAP=virtual><? p($config->auth_instructions) ?></TEXTAREA>
</TD>
<TD>
<? print_string("authinstructions","auth") ?>
<? helpbutton("text", get_string("helptext")) ?>
</TD>
</TR>
+41
View File
@@ -0,0 +1,41 @@
<?PHP // $Id$
// Authentication by looking up an IMAP server
function auth_user_login ($username, $password) {
// Returns true if the username and password work
// and false if they are wrong or don't exist.
global $CFG;
switch ($CFG->auth_imaptype) {
case "imapssl":
$host = "{".$CFG->auth_imaphost.":$CFG->auth_imapport/imap/ssl}";
break;
case "imapcert":
$host = "{".$CFG->auth_imaphost.":$CFG->auth_imapport/imap/ssl/novalidate-cert}";
break;
case "imaptls":
$host = "{".$CFG->auth_imaphost.":$CFG->auth_imapport/imap/notls}";
break;
default:
$host = "{".$CFG->auth_imaphost.":$CFG->auth_imapport}";
}
error_reporting(0);
$connection = imap_open($host, $username, $password, OP_HALFOPEN);
error_reporting(7);
if ($connection) {
imap_close($connection);
return true;
} else {
return false;
}
}
?>
+4
View File
@@ -0,0 +1,4 @@
LDAP-module README
07.10.2002 Version 0.1, Petri Asikainen <paca@sci.fi>
Ldap-authetication module is work in progress.
+168
View File
@@ -0,0 +1,168 @@
<tr valign="top" BGCOLOR="<?=$THEME->cellheading2 ?>">
<TD ALIGN=RIGHT><P>ldap_host_url:</TD>
<TD>
<INPUT name=ldap_host_url TYPE=text SIZE=30 VALUE="<?=$config->ldap_host_url?>">
<? formerr($err["ldap_host_url"]); ?>
</TD>
<TD>
<? print_string("auth_ldap_host_url","auth") ?>
</TD>
</TR>
<TR VALIGN=TOP BGCOLOR="<?=$THEME->cellheading2 ?>">
<TD ALIGN=RIGHT><P>ldap_user_context:</TD>
<TD>
<INPUT name=ldap_contexts TYPE=text SIZE=30 VALUE="<?=$config->ldap_contexts?>">
<? formerr($err["ldap_contexts"]); ?>
</TD>
<TD>
<? print_string("auth_ldap_contexts","auth") ?>
</TD>
</TR>
<TR VALIGN=TOP BGCOLOR="<?=$THEME->cellheading2 ?>">
<TD ALIGN=RIGHT><P>ldap_user_attribute:</TD>
<TD>
<INPUT name=ldap_user_attribute TYPE=text SIZE=30 VALUE="<?=$config->ldap_user_attribute?>">
<? formerr($err["ldap_user_attribute"]); ?>
</TD>
<TD>
<? print_string("auth_ldap_user_attribute","auth") ?>
</TD>
</TR>
<TR VALIGN=TOP BGCOLOR="<?=$THEME->cellheading2 ?>">
<TD ALIGN=RIGHT><P>ldap_search_sub:</TD>
<TD>
<INPUT name=ldap_search_sub TYPE=text SIZE=1 VALUE="<?=$config->ldap_search_sub?>">
<? formerr($err["ldap_search_sub"]); ?>
</TD>
<TD>
<? print_string("auth_ldap_search_sub","auth") ?>
</TD>
</TR>
<TR VALIGN=TOP BGCOLOR="<?=$THEME->cellheading2 ?>">
<TD ALIGN=RIGHT><P>ldap_bind_dn:</TD>
<TD>
<INPUT name=ldap_bind_dn TYPE=text SIZE=30 VALUE="<?=$config->ldap_bind_dn?>">
<? formerr($err["ldap_bind_dn"]); ?>
</TD><TD>
<? print_string("auth_ldap_bind_dn","auth") ?>
</TD>
</TR>
<TR VALIGN=TOP BGCOLOR="<?=$THEME->cellheading2 ?>">
<TD ALIGN=RIGHT><P>ldap_bind_password:</TD>
<TD>
<INPUT name=ldap_bind_pw TYPE=text SIZE=30 VALUE="<?=$config->ldap_bind_pw?>">
<? formerr($err["ldap_bind_pw"]); ?>
</TD><TD>
<? print_string("auth_ldap_bind_pw","auth") ?>
</TD>
</TR>
<TR>
<TD ALIGN=RIGHT><P><? print_string("firstname") ?>:</TD>
<TD>
<INPUT name="auth_user_firstname" TYPE="text" SIZE="30" VALUE="<?=$config->auth_user_firstname?>">
</TD>
<TD rowspan=12 VALIGN=CENTER>
<? print_string("auth_ldapextrafields","auth") ?>
</TD>
</TR>
<TR VALIGN=TOP>
<TD ALIGN=RIGHT><P><? print_string("lastname") ?>:</TD>
<TD>
<INPUT name="auth_user_lastname" TYPE="text" SIZE="30" VALUE="<?=$config->auth_user_lastname?>">
</TD>
</TR>
<TR VALIGN=TOP>
<TD ALIGN=RIGHT><P><? print_string("email") ?>:</TD>
<TD>
<INPUT name="auth_user_email" TYPE="text" SIZE="30" VALUE="<?=$config->auth_user_email?>">
</TD>
</TR>
<TR VALIGN=TOP>
<TD ALIGN=RIGHT><P><? print_string("phone") ?> 1:</TD>
<TD>
<INPUT name="auth_user_phone1" TYPE="text" SIZE="30" VALUE="<?=$config->auth_user_phone1?>">
</TD>
</TR>
<TR VALIGN=TOP>
<TD ALIGN=RIGHT><P><? print_string("phone") ?> 2:</TD>
<TD>
<INPUT name="auth_user_phone2" TYPE="text" SIZE="30" VALUE="<?=$config->auth_user_phone2?>">
</TD>
</TR>
<TR VALIGN=TOP>
<TD ALIGN=RIGHT><P><? print_string("department") ?>:</TD>
<TD>
<INPUT name="auth_user_department" TYPE="text" SIZE="30" VALUE="<?=$config->auth_user_department?>">
</TD>
</TR>
<TR VALIGN=TOP>
<TD ALIGN=RIGHT><P><? print_string("address") ?>:</TD>
<TD>
<INPUT name="auth_user_address" TYPE="text" SIZE="30" VALUE="<?=$config->auth_user_address?>">
</TD>
</TR>
<TR VALIGN=TOP>
<TD ALIGN=RIGHT><P><? print_string("city") ?>:</TD>
<TD>
<INPUT name="auth_user_city" TYPE="text" SIZE="30" VALUE="<?=$config->auth_user_city?>">
</TD>
</TR>
<TR VALIGN=TOP>
<TD ALIGN=RIGHT><P><? print_string("country") ?>:</TD>
<TD>
<INPUT name="auth_user_country" TYPE="text" SIZE="30" VALUE="<?=$config->auth_user_country?>">
</TD>
</TR>
<TR VALIGN=TOP>
<TD ALIGN=RIGHT><P><? print_string("description") ?>:</TD>
<TD>
<INPUT name="auth_user_description" TYPE="text" SIZE="30" VALUE="<?=$config->auth_user_description?>">
</TD>
</TR>
<TR VALIGN=TOP>
<TD ALIGN=RIGHT><P><? print_string("idnumber") ?>:</TD>
<TD>
<INPUT name="auth_user_idnumber" TYPE="text" SIZE="30" VALUE="<?=$config->auth_user_idnumber?>">
</TD>
</TR>
<TR VALIGN=TOP>
<TD ALIGN=RIGHT><P><? print_string("language") ?>:</TD>
<TD>
<INPUT name="auth_user_lang" TYPE="text" SIZE="30" VALUE="<?=$config->auth_user_lang?>">
</TD>
</TR>
<TR VALIGN=TOP>
<TD ALIGN=RIGHT><P><? print_string("instructions", "auth") ?>:</TD>
<TD>
<TEXTAREA NAME=auth_instructions COLS=30 ROWS=10 WRAP=virtual><? p($config->auth_instructions) ?></TEXTAREA>
</TD>
<TD>
<? print_string("authinstructions","auth") ?>
<? helpbutton("text", get_string("helptext")) ?>
</TD>
</TR>
+181
View File
@@ -0,0 +1,181 @@
<?PHP
//CHANGELOG:
//03.10.2002 First version to CVS
//29.09.2002 Clean up and splitted code to functions v. 0.02
//29.09.2002 LDAP authentication functions v. 0.01
//Distributed under GPL (c)Petri Asikainen 2002
function auth_user_login ($username, $password) {
// Returns true if the username and password work
// and false if they don't
global $CFG;
$ldap_connection = auth_ldap_connect();
if($ldap_connection) {
$ldap_user_dn = auth_ldap_find_userdn($ldap_connection, $username);
//if ldap_user_dn is empty, user does not exist
if(!$ldap_user_dn){
return false;
}
// Try to bind with current username and password
$ldap_login = @ldap_bind($ldap_connection, $ldap_user_dn, $password);
if ($ldap_login) {
ldap_close($ldap_connection);
return true;
}
} else {
@ldap_close($ldap_connection);
error("LDAP-module cannot connect to server: $CFG->ldap_host_url");
return false ;
}
}
function auth_get_userinfo($username){
global $CFG;
//reads userinformation from ldap and return it in array()
$config = (array)$CFG;
$fields = array("firstname", "lastname", "email", "phone1", "phone2",
"department", "address", "city", "country", "description",
"idnumber", "lang");
$moodleattributes = array();
foreach ($fields as $field) {
if ($config["auth_user_$field"]) {
$moodleattributes[$field] = $config["auth_user_$field"];
}
}
$ldap_connection=auth_ldap_connect();
$result = array();
$search_attribs = array();
foreach ($moodleattributes as $key=>$value) {
array_push($search_attribs, $value);
}
$user_dn = auth_ldap_find_userdn($ldap_connection, $username);
if (! isset($CFG->ldap_objectclass)) {
$CFG->ldap_objectclass="objectClass=*";
}
$user_info_result = ldap_read($ldap_connection,$user_dn,$CFG->ldap_objectclass, $search_attribs);
if ($user_info_result) {
$user_entry = ldap_get_entries($ldap_connection, $user_info_result);
foreach ($moodleattributes as $key=>$value){
if(isset($user_entry[0][$value][0])){
$result[$key]=$user_entry[0][$value][0];
}
}
}
@ldap_close($ldap_connection);
return $result;
}
function auth_get_userlist() {
//returns all users from ldap servers
global $CFG;
$fresult = array();
$ldap_connection = auth_ldap_connect();
auth_ldap_bind($ldap_connection);
if (! isset($CFG->ldap_objectclass)) {
$CFG->ldap_objectclass="objectClass=*";
}
$contexts=explode(";",$CFG->ldap_contexts);
foreach ($contexts as $context) {
if($CFG->ldap_search_sub){
//use ldap_search to find first user from subtree
$ldap_result = ldap_search($ldap_connection, $context, "(".$CFG->ldap_objectclass.")", array($CFG->ldap_user_attribute));
} else {
//search only in this context
$ldap_result = ldap_list($ldap_connection, $context, "(".$CFG->ldap_objectclass.")", array($CFG->ldap_user_attribute));
}
$users = ldap_get_entries($ldap_connection,$ldap_result);
//add found users to list
for ($i=0;$i<$users['count'];$i++) {
array_push($fresult,($users[$i][$CFG->ldap_user_attribute][0]));
}
}
return $fresult;
}
function auth_ldap_connect(){
//connects to ldap-server
global $CFG;
$result = ldap_connect($CFG->ldap_host_url);
if ($result) {
return $result;
} else {
error("LDAP-module cannot connect to server: $CFG->ldap_host_url");
return false;
}
}
function auth_ldap_bind($ldap_connection){
//makes bind to ldap for searching users
//uses ldap_bind_dn or anonymous bind
global $CFG;
if ($CFG->ldap_bind_dn){
//bind with search-user
if (!ldap_bind($ldap_connection, $CFG->ldap_bind_dn,$CFG->ldap_bind_pw)){
error("Error: could not bind ldap with ldap_bind_dn/pw");
return false;
}
}else{
//bind anonymously
if ( !ldap_bind($ldap_connection)){
error("Error: could not bind ldap anonymously");
return false;
}
}
return true;
}
function auth_ldap_find_userdn ($ldap_connection, $username){
//return dn of username
//like: cn=username,ou=suborg,o=org
//or false if username not found
global $CFG;
//default return value
$ldap_user_dn = FALSE;
auth_ldap_bind($ldap_connection);
//get all contexts and look for first matching user
$ldap_contexts = explode(";",$CFG->ldap_contexts);
foreach($ldap_contexts as $context) {
$context == trim($context);
if($CFG->ldap_search_sub){
//use ldap_search to find first user from subtree
$ldap_result = ldap_search($ldap_connection, $context, "(".$CFG->ldap_user_attribute."=".$username.")");
} else {
//search only in this context
$ldap_result = ldap_list($ldap_connection, $context, "(".$CFG->ldap_user_attribute."=".$username.")");
}
$entry = ldap_first_entry($ldap_connection,$ldap_result);
if ($entry){
$ldap_user_dn = ldap_get_dn($ldap_connection, $entry);
break ;
}
}
return $ldap_user_dn;
}
?>
+32
View File
@@ -0,0 +1,32 @@
<tr valign="top" BGCOLOR="<?=$THEME->cellheading2 ?>">
<TD ALIGN=RIGHT><P>auth_nntphost:</TD>
<TD>
<INPUT name="auth_nntphost" TYPE="text" SIZE=30 VALUE="<?=$config->auth_nntphost?>">
<? formerr($err["ldap_nntphost"]); ?>
</TD>
<TD>
<? print_string("auth_nntphost","auth") ?>
</TD>
</TR>
<TR VALIGN=TOP BGCOLOR="<?=$THEME->cellheading2 ?>">
<TD ALIGN=RIGHT><P>auth_nntpport:</TD>
<TD>
<INPUT name=auth_imapport TYPE=text SIZE=6 VALUE="<?=$config->auth_nntpport?>">
<? formerr($err["auth_nntpport"]); ?>
</TD>
<TD>
<? print_string("auth_nntpport","auth") ?>
</TD>
</TR>
<TR VALIGN=TOP>
<TD ALIGN=RIGHT><P><? print_string("instructions", "auth") ?>:</TD>
<TD>
<TEXTAREA NAME=auth_instructions COLS=30 ROWS=10 WRAP=virtual><? p($config->auth_instructions) ?></TEXTAREA>
</TD>
<TD>
<? print_string("authinstructions","auth") ?>
<? helpbutton("text", get_string("helptext")) ?>
</TD>
</TR>
+30
View File
@@ -0,0 +1,30 @@
<?PHP // $Id$
// Authentication by looking up an NNTP server
// This code is completely untested so far - IT NEEDS TESTERS!
// Looks like it should work though ...
function auth_user_login ($username, $password) {
// Returns true if the username and password work
// and false if they are wrong or don't exist.
global $CFG;
$host = "{".$CFG->auth_nntphost.":$CFG->auth_nntpport/nntp}";
error_reporting(0);
$connection = imap_open($host, $username, $password, OP_HALFOPEN);
error_reporting(7);
if ($connection) {
imap_close($connection);
return true;
} else {
return false;
}
}
?>
+1
View File
@@ -0,0 +1 @@
<!-- No config needed -->
+17
View File
@@ -0,0 +1,17 @@
<?PHP // $Id$
// No authentication at all. This method approves everything!
function auth_user_login ($username, $password) {
// Returns true if the username doesn't exist yet
// Returns true if the username and password work
if (! $user = get_user_info_from_db("username", $username)) {
return true;
}
return ($user->password == md5($password));
}
?>
+48
View File
@@ -0,0 +1,48 @@
<tr valign="top" BGCOLOR="<?=$THEME->cellheading2 ?>">
<TD ALIGN=RIGHT><P>auth_pop3host:</TD>
<TD>
<INPUT name=auth_pop3host TYPE=text SIZE=30 VALUE="<?=$config->auth_pop3host?>">
<? formerr($err["ldap_host_url"]); ?>
</TD>
<TD>
<? print_string("auth_pop3host","auth") ?>
</TD>
</TR>
<TR VALIGN=TOP BGCOLOR="<?=$THEME->cellheading2 ?>">
<TD ALIGN=RIGHT><P>auth_pop3type:</TD>
<TD>
<? $pop3types = array("pop3","pop3cert");
foreach($pop3types as $pop3type) {
$pop3options[$pop3type] = $pop3type;
}
choose_from_menu($pop3options, "auth_pop3type", $config->auth_pop3type, "");
?>
<? formerr($err["auth_pop3type"]); ?>
</TD>
<TD>
<? print_string("auth_pop3type","auth") ?>
</TD>
</TR>
<TR VALIGN=TOP BGCOLOR="<?=$THEME->cellheading2 ?>">
<TD ALIGN=RIGHT><P>auth_pop3port:</TD>
<TD>
<INPUT name=auth_pop3port TYPE=text SIZE=6 VALUE="<?=$config->auth_pop3port?>">
<? formerr($err["auth_pop3port"]); ?>
</TD>
<TD>
<? print_string("auth_pop3port","auth") ?>
</TD>
</TR>
<TR VALIGN=TOP>
<TD ALIGN=RIGHT><P><? print_string("instructions", "auth") ?>:</TD>
<TD>
<TEXTAREA NAME=auth_instructions COLS=30 ROWS=10 WRAP=virtual><? p($config->auth_instructions) ?></TEXTAREA>
</TD>
<TD>
<? print_string("authinstructions","auth") ?>
<? helpbutton("text", get_string("helptext")) ?>
</TD>
</TR>
+36
View File
@@ -0,0 +1,36 @@
<?PHP // $Id$
// Authentication by looking up a POP3 server
// This code is completely untested so far - IT NEEDS TESTERS!
// Looks like it should work though ...
function auth_user_login ($username, $password) {
// Returns true if the username and password work
// and false if they are wrong or don't exist.
global $CFG;
switch ($CFG->auth_pop3type) {
case "pop3":
$host = "{".$CFG->auth_pop3host.":$CFG->auth_pop3port/pop3}INBOX";
break;
case "pop3cert":
$host = "{".$CFG->auth_pop3host.":$CFG->auth_pop3port/pop3/ssl/novalidate-cert}INBOX";
break;
}
error_reporting(0);
$connection = imap_open($host, $username, $password, OP_HALFOPEN);
error_reporting(7);
if ($connection) {
imap_close($connection);
return true;
} else {
return false;
}
}
?>
+86 -130
View File
@@ -1,130 +1,86 @@
<?PHP // $Id$
///////////////////////////////////////////////////////////////////////////
//
// Moodle configuration file
//
// This file should be located in the top-level directory.
//
///////////////////////////////////////////////////////////////////////////
//
// NOTICE OF COPYRIGHT
//
// Moodle - Modular Object-Oriented Dynamic Learning Environment
// http://moodle.com
//
// Copyright (C) 2001 Martin Dougiamas http://dougiamas.com
//
// This program is free software; you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation; either version 2 of the License, or
// (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details:
//
// http://www.gnu.org/copyleft/gpl.html
//
////////////////////////////////////////////////////////////////////////////
//
// Site configuration variables are all stored in the CFG object.
// First, you need to configure the database where all Moodle data
// will be stored. This database must already have been created
// and a username/password created to access it. See doc/INSTALL.
$CFG->dbtype = "mysql"; // eg mysql (postgres7, oracle, access etc coming soon)
$CFG->dbhost = "localhost"; // eg localhost
$CFG->dbname = "moodle"; // eg moodle
$CFG->dbuser = "username";
$CFG->dbpass = "password";
// Next you need to tell Moodle where it is located.
// Specify the full URL that moodle has been installed in:
$CFG->wwwroot = "http://example.com/moodle";
// and now the full OS directory path to this same location:
$CFG->dirroot = "/web/moodle";
// Now you need a place where Moodle can save uploaded files. This directory
// should be writeable by the web server user (usually 'nobody' or 'apache'),
// but it should not be accessible directly via the web.
$CFG->dataroot = "/home/moodledata";
// Choose a sitewide language - this will affect text, buttons etc
// See lib/languages.php for a full list of standard language codes.
$CFG->lang = "en"; // Currently the only option
// Choose a sitewide locale - this will affect the display of dates
// You need to have this locale data installed on your operating
// system. If you don't know what to choose try using the same
// string as the language.
$CFG->locale = "en";
// Give the full names of local SMTP servers that Moodle should use to
// send mail (eg "mail.a.com" or "mail.a.com;mail.b.com").
// If this is left empty (eg "") then Moodle will attempt to use PHP mail.
$CFG->smtphosts = "";
// There is no way, currently, for PHP to automatically tell whether the
// graphic library GD is version 1.* or 2.*. Specify here (either 1 or 2).
$CFG->gdversion = 1;
// If students haven't logged in for a very long time, then they are
// automatically unsubscribed from courses. This parameter specifies
// that time limit, in DAYS.
$CFG->longtimenosee = 100;
// These programs are used by the file management code to zip and unzip
// uploaded files. This only works on Unix systems right now.
$CFG->zip = "/usr/bin/zip";
$CFG->unzip = "/usr/bin/unzip";
// Files (images, uploads etc) are provided via a script which
// is called like this example: file.php/1/myfiles/mymusic.mp3
// Using this form of argument allows files to be more easily
// cached in web browsers, proxy servers etc, but they don't
// work in all PHP servers. If you have trouble viewing
// uploaded files or images, then set the following to false
$CFG->slasharguments = true;
// If this server needs to use a proxy computer (eg a firewall)
// to access the Internet, then provide the proxy details here.
// This will only affect a few minor features such as the ability
// to see user locations plotted on a graph.
// Otherwise, leave these blank
$CFG->proxyhost = "";
$CFG->proxyport = "";
// You should not need to change anything else. To continue setting up
// Moodle, use your web browser to go to the moodle/admin web page.
///////////////////////////////////////////////////////////////////////////
$CFG->libdir = "$CFG->dirroot/lib";
require("$CFG->libdir/setup.php"); // Sets up all libraries, sessions etc
?>
<?PHP // $Id$
///////////////////////////////////////////////////////////////////////////
// //
// Moodle configuration file //
// //
// This file should be renamed "config.php" in the top-level directory //
// //
///////////////////////////////////////////////////////////////////////////
// //
// NOTICE OF COPYRIGHT //
// //
// Moodle - Modular Object-Oriented Dynamic Learning Environment //
// http://moodle.com //
// //
// Copyright (C) 2001-2002 Martin Dougiamas http://dougiamas.com //
// //
// This program is free software; you can redistribute it and/or modify //
// it under the terms of the GNU General Public License as published by //
// the Free Software Foundation; either version 2 of the License, or //
// (at your option) any later version. //
// //
// This program is distributed in the hope that it will be useful, //
// but WITHOUT ANY WARRANTY; without even the implied warranty of //
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the //
// GNU General Public License for more details: //
// //
// http://www.gnu.org/copyleft/gpl.html //
// //
///////////////////////////////////////////////////////////////////////////
///////////////////////////////////////////////////////////////////////////
// First, you need to configure the database where all Moodle data //
// will be stored. This database must already have been created //
// and a username/password created to access it. If you specify mysql //
// then Moodle can set up all your tables for you. If you try to use //
// a different database you will need to set up all your tables by hand //
// which could be a big job. See doc/install.html //
$CFG->dbtype = "mysql"; // eg mysql (postgres7, oracle, access etc)
$CFG->dbhost = "localhost"; // eg localhost
$CFG->dbname = "moodle"; // eg moodle
$CFG->dbuser = "username";
$CFG->dbpass = "password";
///////////////////////////////////////////////////////////////////////////
// Now you need to tell Moodle where it is located. Specify the full
// web address where moodle has been installed (without trailing slash)
$CFG->wwwroot = "http://example.com/moodle";
///////////////////////////////////////////////////////////////////////////
// Next, specify the full OS directory path to this same location
// For Windows this might be something like "C:\apache\htdocs\moodle"
$CFG->dirroot = "/web/moodle";
///////////////////////////////////////////////////////////////////////////
// Now you need a place where Moodle can save uploaded files. This
// directory should be writeable by the web server user (usually 'nobody'
// or 'apache'), but it should not be accessible directly via the web.
$CFG->dataroot = "/home/moodledata";
///////////////////////////////////////////////////////////////////////////
// A very small percentage of servers have a bug which causes HTTP_REFERER
// not to work. The symptoms of this are that you fill out the configure
// form during Moodle setup but when hit save you find yourself on the
// same form, unable to progress. If this happens to you, come back here
// and set the following to true. Otherwise this should always be false.
$CFG->buggy_referer = false;
///////////////////////////////////////////////////////////////////////////
// To continue the setup, use your web browser to go to your Moodle page //
///////////////////////////////////////////////////////////////////////////
$CFG->libdir = "$CFG->dirroot/lib"; // Do not change this
require("$CFG->libdir/setup.php"); // Do not change this
?>
+123
View File
@@ -0,0 +1,123 @@
<?PHP // $Id$
// Allows the admin to create, delete and rename course categories
require("../config.php");
require("lib.php");
if (!isadmin()) {
error("Only administrators can use this course!");
}
if (!$site = get_site()) {
error("Site isn't defined!");
}
/// Print headings
$stradministration = get_string("administration");
$strcategories = get_string("categories");
$strcategory = get_string("category");
$strcourses = get_string("courses");
$stredit = get_string("edit");
$strdelete = get_string("delete");
$straction = get_string("action");
$stradd = get_string("add");
print_header("$site->shortname: $strcategories", "$site->fullname",
"<A HREF=\"$CFG->wwwroot/admin\">$stradministration</A> -> $strcategories");
print_heading($strcategories);
/// If data submitted, then process and store.
if (match_referer() && isset($HTTP_POST_VARS)) {
$categories = array();
// Peel out all the data from variable names.
foreach ($HTTP_POST_VARS as $key => $val) {
if ($key == "new" and $val != "") {
$cat->name = $val;
if (!insert_record("course_categories", $cat)) {
error("Could not insert the new category '$val'");
} else {
notify(get_string("categoryadded", "", $val));
}
} else {
$cat->id = substr($key,1);
$cat->name = $val;
if (!update_record("course_categories", $cat)) {
error("Could not update the category '$val'");
}
}
}
}
/// Get the existing categories
if (!$categories = get_all_categories()) {
// Try and make one
$cat->name = get_string("miscellaneous");
if ($cat->id = insert_record("course_categories", $cat)) {
$categories[$cat->id] = $cat;
} else {
error("Serious error: Could not create a default category!");
}
}
/// Delete category if the user wants to delete it
if (isset($delete)) {
if (delete_records("course_categories", "id", $delete)) {
notify(get_string("categorydeleted", "", $categories[$delete]->name));
unset($categories[$delete]);
} else {
error("An error occurred while trying to delete a category");
}
}
/// Find lowest ID category - this is the default category
$default = 99999;
foreach ($categories as $category) {
if ($category->id < $default) {
$default = $category->id;
}
}
/// Find any orphan courses that don't yet have a valid category and set to default
if ($courses = get_records_sql("SELECT * FROM course WHERE category > 0")) {
foreach ($courses as $course) {
if (!isset( $categories[$course->category] )) {
set_field("course", "category", $default, "id", $course->id);
}
}
}
/// Print the table of all categories
$table->head = array ($strcategory, $strcourses, $straction);
$table->align = array ("LEFT", "CENTER", "CENTER");
$table->size = array ("80", "50", "50");
$table->width = 100;
echo "<FORM ACTION=categories.php METHOD=post>";
foreach ($categories as $category) {
$count = count_records("course", "category", $category->id);
if ($category->id == $default) {
$delete = ""; // Can't delete default category
} else {
$delete = "<A HREF=\"categories.php?delete=$category->id\">$strdelete</A>";
}
$table->data[] = array ("<INPUT TYPE=text NAME=\"c$category->id\" VALUE=\"$category->name\" SIZE=30>",
"<A HREF=\"index.php?category=$category->id\">$count</A>", $delete);
}
$table->data[] = array ("<INPUT TYPE=text NAME=\"new\" VALUE=\"\" SIZE=30>", "", "$stradd");
print_table($table);
echo "<CENTER><BR><INPUT TYPE=submit VALUE=\"".get_string("savechanges")."\"> ";
echo "</CENTER>";
echo "</FORM>";
print_footer();
?>
+3 -3
View File
@@ -20,7 +20,7 @@
$stradministration = get_string("administration");
if (!$id) {
print_header("$site->fullname : $strdeletecourse", $site->fullname,
print_header("$site->shortname: $strdeletecourse", $site->fullname,
"<A HREF=\"$CFG->wwwroot/admin\">$stradministration</A> -> $strdeletecourse");
if ($courses = get_records_sql("SELECT * from course WHERE category > 0 ORDER BY fullname")) {
@@ -45,7 +45,7 @@
if (! $delete) {
$strdeletecheck = get_string("deletecheck", "", $course->shortname);
$strdeletecoursecheck = get_string("deletecoursecheck");
print_header("$site->fullname : $strdeletecheck", $site->fullname,
print_header("$site->shortname: $strdeletecheck", $site->fullname,
"<A HREF=\"$CFG->wwwroot/admin\">$stradministration</A> ->
<A HREF=\"delete.php\">$strdeletecourse</A> -> $strdeletecheck");
@@ -62,7 +62,7 @@
// OK checks done, delete the course now.
$strdeletingcourse = get_string("deletingcourse", "", $course->shortname);
print_header("$site->fullname : $strdeletingcourse", $site->fullname,
print_header("$site->shortname: $strdeletingcourse", $site->fullname,
"<A HREF=\"$CFG->wwwroot/admin\">$stradministration</A> ->
<A HREF=\"delete.php\">$strdeletecourse</A> -> $strdeletingcourse");
+23 -1
View File
@@ -90,7 +90,7 @@
<tr valign=top>
<td><P><? print_string("numberweeks") ?>:</td>
<td><?
for ($i=1; $i<=20; $i++) {
for ($i=1; $i<=52; $i++) {
$sectionmenu[$i] = "$i";
}
choose_from_menu ($sectionmenu, "numsections", "$form->numsections");
@@ -98,18 +98,40 @@
formerr($err["numsections"]);
?></td>
</tr>
<tr valign=top>
<td><P><? print_string("showrecent") ?>:</td>
<td><?
unset($choices);
$choices["0"] = get_string("no");
$choices["1"] = get_string("yes");
choose_from_menu ($choices, "showrecent", $form->showrecent, "");
helpbutton("courserecent", get_string("showrecent")); ?>
</td>
</tr>
<tr valign=top>
<td><P><? print_string("wordforteacher") ?>:</td>
<td><input type="text" name="teacher" size=25 value="<? p($form->teacher) ?>">
(<? print_string("wordforteachereg") ?>) <? formerr($err["teacher"]) ?>
</td>
</tr>
<tr valign=top>
<td><P><? print_string("wordforteachers") ?>:</td>
<td><input type="text" name="teachers" size=25 value="<? p($form->teachers) ?>">
(<? print_string("wordforteacherseg") ?>) <? formerr($err["teachers"]) ?>
</td>
</tr>
<tr valign=top>
<td><P><? print_string("wordforstudent") ?>:</td>
<td><input type="text" name="student" size=25 value="<? p($form->student) ?>">
(<? print_string("wordforstudenteg") ?>) <? formerr($err["student"]) ?>
</td>
</tr>
<tr valign=top>
<td><P><? print_string("wordforstudents") ?>:</td>
<td><input type="text" name="students" size=25 value="<? p($form->students) ?>">
(<? print_string("wordforstudentseg") ?>) <? formerr($err["students"]) ?>
</td>
</tr>
<tr>
<td></td>
<td><input type="submit" value="<? print_string("savechanges") ?>"></td>
+5 -2
View File
@@ -84,11 +84,14 @@
$form->fullname = get_string("defaultcoursefullname");
$form->shortname = get_string("defaultcourseshortname");
$form->teacher = get_string("defaultcourseteacher");
$form->teachers = get_string("defaultcourseteachers");
$form->student = get_string("defaultcoursestudent");
$form->students = get_string("defaultcoursestudents");
$form->summary = get_string("defaultcoursesummary");
$form->format = "weeks";
$form->numsections = 10;
$form->newsitems = 5;
$form->showrecent = 1;
$form->category = 1;
}
}
@@ -110,13 +113,13 @@
"<A HREF=\"$CFG->wwwroot/course/view.php?id=$course->id\">$course->shortname</A>
-> $streditcoursesettings", $focus);
} else {
print_header("$site->shortname : $straddnewcourse", "$site->fullname",
print_header("$site->shortname: $straddnewcourse", "$site->fullname",
"<A HREF=\"$CFG->wwwroot/admin/\">$stradministration</A>
-> $straddnewcourse", $focus);
}
print_simple_box_start("center", "", "$THEME->cellheading");
print_heading($streditcoursesettings);
print_simple_box_start("center", "", "$THEME->cellheading");
include("edit.html");
print_simple_box_end();
+1 -1
View File
@@ -30,7 +30,7 @@
<td width=50%>
<table cellpadding=1 cellspacing=0><tr>
<td><input type=submit value="<? print_string("login") ?>"></form></td>
<td><form action="<?=$CFG->wwwroot?>/" method=post>
<td><form action="<?=$CFG->wwwroot?>/index.php" method=post>
<input type=submit value="<? print_string("cancel") ?>"></form></td>
</tr></table>
+2 -2
View File
@@ -19,7 +19,7 @@
add_to_log($course->id, "course", "guest", "view.php?id=$course->id", "$REMOTE_ADDR, $REMOTE_HOST");
} else {
if (! enrol_student_in_course($USER->id, $course->id)) {
if (! enrol_student($USER->id, $course->id)) {
error("An error occurred while trying to enrol you.");
}
@@ -65,7 +65,7 @@
if (isguest()) {
add_to_log($course->id, "course", "guest", "view.php?id=$course->id", "$USER->id");
} else {
if (! enrol_student_in_course($USER->id, $course->id)) {
if (! enrol_student($USER->id, $course->id)) {
error("An error occurred while trying to enrol you.");
}
add_to_log($course->id, "course", "enrol", "view.php?id=$course->id", "$USER->id");
+211
View File
@@ -0,0 +1,211 @@
<?PHP // $Id$
// Displays all grades for a course
require("../config.php");
require("lib.php");
require("$CFG->libdir/psxlsgen.php");
require_variable($id); // course id
optional_variable($download, ""); // to download data
if (! $course = get_record("course", "id", $id)) {
error("Course ID was incorrect");
}
require_login($course->id);
if (!isteacher($course->id)) {
error("Only teachers can use this page!");
}
$strgrades = get_string("grades");
$strgrade = get_string("grade");
$strmax = get_string("maximumshort");
$stractivityreport = get_string("activityreport");
/// Get a list of all students
if (!$students = get_course_students($course->id)) {
print_heading(get_string("nostudentsyet"));
print_footer($course);
exit;
}
foreach ($students as $student) {
$grades[$student->id] = array(); // Collect all grades in this array
$totals[$student->id] = array(); // Collect all totals in this array
}
$columns = array(); // Accumulate column names in this array.
$columnhtml = array(); // Accumulate column html in this array.
/// Collect modules data
get_all_mods($course->id, $mods, $modnames, $modnamesplural, $modnamesused, $modsectioncounts);
/// Search through all the modules, pulling out grade data
$sections = get_all_sections($course->id); // Sort everything the same as the course
for ($i=0; $i<=$course->numsections; $i++) {
if (isset($sections[$i])) { // should always be true
$section = $sections[$i];
if ($section->sequence) {
$sectionmods = explode(",", $section->sequence);
foreach ($sectionmods as $sectionmod) {
$mod = $mods[$sectionmod];
$instance = get_record("$mod->modname", "id", "$mod->instance");
$libfile = "$CFG->dirroot/mod/$mod->modname/lib.php";
if (file_exists($libfile)) {
require_once($libfile);
$gradefunction = $mod->modname."_grades";
if (function_exists($gradefunction)) { // Skip modules without grade function
if ($modgrades = $gradefunction($mod->instance)) {
if ($modgrades->maxgrade) {
$maxgrade = "<BR>$strmax: $modgrades->maxgrade";
} else {
$maxgrade = "";
}
$image = "<A HREF=\"$CFG->wwwroot/mod/$mod->modname/view.php?id=$mod->id\"".
" TITLE=\"$mod->modfullname\">".
"<IMG BORDER=0 VALIGN=absmiddle SRC=\"../mod/$mod->modname/icon.gif\" ".
"HEIGHT=16 WIDTH=16 ALT=\"$mod->modfullname\"></A>";
$columnhtml[] = "$image ".
"<A HREF=\"$CFG->wwwroot/mod/$mod->modname/view.php?id=$mod->id\">".
"$instance->name".
"</A>$maxgrade";
$columns[] = "$mod->modfullname: $instance->name - $modgrades->maxgrade";
foreach ($students as $student) {
$grades[$student->id][] = $modgrades->grades[$student->id]; // may be empty, that's ok
if ($modgrades->maxgrade) {
$totals[$student->id] = (float)($totals[$student->id]) + (float)($modgrades->grades[$student->id]);
} else {
$totals[$student->id] = (float)($totals[$student->id]) + 0;
}
}
}
}
}
}
}
}
} // a new Moodle nesting record? ;-)
/// OK, we have all the data, now present it to the user
if ($download == "xls") {
$myxls = new PhpSimpleXlsGen();
$myxls->totalcol = count($columns) + 5;
/// Print names of all the fields
$myxls->ChangePos(0,0);
$myxls->InsertText(get_string("firstname"));
$myxls->InsertText(get_string("lastname"));
foreach ($columns as $column) {
$myxls->InsertText($column);
}
$myxls->InsertText(get_string("total"));
/// Print all the lines of data.
$i = 0;
foreach ($grades as $studentid => $studentgrades) {
$i++;
$student = $students[$studentid];
$myxls->ChangePos($i,0);
$myxls->InsertText($student->firstname);
$myxls->InsertText($student->lastname);
foreach ($studentgrades as $grade) {
$myxls->InsertText($grade);
}
$myxls->InsertNumber($totals[$student->id]);
}
$myxls->SendFile("$course->shortname $strgrades");
exit;
} else if ($download == "txt") {
/// Print header to force download
header("Content-Type: application/download\n");
header("Content-Disposition: attachment; filename=\"$course->shortname $strgrades.txt\"");
/// Print names of all the fields
echo get_string("firstname")."\t".get_string("lastname");
foreach ($columns as $column) {
echo "\t$column";
}
echo "\t".get_string("total")."\n";
/// Print all the lines of data.
foreach ($grades as $studentid => $studentgrades) {
$student = $students[$studentid];
echo "$student->firstname\t$student->lastname";
foreach ($studentgrades as $grade) {
echo "\t$grade";
}
echo "\t".$totals[$student->id];
echo "\n";
}
exit;
} else { // Just print the web page
print_header("$course->shortname: $strgrades", "$course->fullname",
"<A HREF=\"$CFG->wwwroot/course/view.php?id=$course->id\">$course->shortname</A>
-> $strgrades");
print_heading($strgrades);
$table->head = array_merge(array ("", get_string("name")), $columnhtml, get_string("total"));
$table->width = array(35, "");
$table->align = array("LEFT", "LEFT");
foreach ($columns as $column) {
$table->width[] = "";
$table->align[] = "CENTER";
}
$table->width[] = "";
$table->align[] = "CENTER";
foreach ($grades as $studentid => $studentgrades) {
$student = $students[$studentid];
$picture = print_user_picture($student->id, $course->id, $student->picture, false, true);
$name = array ("$picture", "<A TITLE=\"$stractivityreport\" HREF=\"user.php?id=$course->id&user=$student->id\">$student->firstname&nbsp;$student->lastname</A>");
$total = array ($totals[$student->id]);
$table->data[] = array_merge($name, $studentgrades, $total);
}
print_table($table);
echo "<TABLE BORDER=0 ALIGN=CENTER><TR>";
echo "<TD>";
$options["id"] = "$course->id";
$options["download"] = "xls";
print_single_button("grades.php", $options, get_string("downloadexcel"));
echo "<TD>";
$options["download"] = "txt";
print_single_button("grades.php", $options, get_string("downloadtext"));
echo "</TABLE>";
print_footer($course);
}
?>
+41 -5
View File
@@ -4,15 +4,51 @@
require("../config.php");
require("lib.php");
$title = get_string("courses");
optional_variable($category, "");
print_header($title, $title, $title, "");
$strcourses = get_string("courses");
$strcategories = get_string("categories");
$strmycourses = get_string("mycourses");
$strfulllistofcourses = get_string("fulllistofcourses");
optional_variable($cat, 1);
if (!$categories = get_all_categories()) {
error("Could not find any course categories!");
}
echo "<TABLE WIDTH=80% ALIGN=CENTER><TR><TD>";
if ($category == "all") {
$title = $strfulllistofcourses;
$navigation = "<A HREF=\"index.php\">$strcourses</A> -> $title";
} else if ($category == "my") {
$title = $strmycourses;
$navigation = "<A HREF=\"index.php\">$strcourses</A> -> $title";
} else if (isset($categories[$category])) {
$title = $categories[$category]->name;
$navigation = "<A HREF=\"index.php\">$strcourses</A> -> $title";
} else {
$navigation = $strcourses;
}
print_all_courses($cat);
print_header($strcourses, $strcourses, $navigation);
$showcategories = (count($categories) > 1);
if ($showcategories) {
echo "<TABLE WIDTH=\"100%\" CELLPADDING=10 BORDER=0>";
echo "<TR><TD WIDTH=180 VALIGN=TOP>";
print_course_categories($categories, $category, 180);
echo "</TD><TD WIDTH=\"100%\" VALIGN=TOP>";
} else {
echo "<TABLE WIDTH=80% ALIGN=CENTER><TR><TD VALIGN=top>";
$category="all";
unset($title);
}
if ($category) {
if (isset($title)) {
print_heading_block($title);
}
echo "<BR>";
print_all_courses($category);
}
echo "</TD></TR></TABLE>";
+322 -167
View File
@@ -31,6 +31,9 @@ function print_log_selector_form($course, $selecteduser=0, $selecteddate="today"
$users["$teacher->id"] = "$teacher->firstname $teacher->lastname";
}
}
if ($guest = get_user_info_from_db("username", "guest")) {
$users["$guest->id"] = "$guest->firstname $guest->lastname";
}
}
if (isadmin()) {
@@ -58,7 +61,7 @@ function print_log_selector_form($course, $selecteduser=0, $selecteddate="today"
$timemidnight = $today = usergetmidnight($timenow);
// Put today up the top of the list
$dates = array("$timemidnight" => get_string("today").", ".userdate($timenow, "%e %B %Y") );
$dates = array("$timemidnight" => get_string("today").", ".userdate($timenow, "%d %B %Y") );
if (! $course->startdate) {
$course->startdate = $course->timecreated;
@@ -68,7 +71,7 @@ function print_log_selector_form($course, $selecteduser=0, $selecteddate="today"
while ($timemidnight > $course->startdate and $numdates < 365) {
$timemidnight = $timemidnight - 86400;
$timenow = $timenow - 86400;
$dates["$timemidnight"] = userdate($timenow, "%A, %e %B %Y");
$dates["$timemidnight"] = userdate($timenow, "%A, %d %B %Y");
$numdates++;
}
@@ -157,7 +160,7 @@ function print_log($course, $user=0, $date=0, $order="ORDER BY l.time ASC") {
echo "<TD NOWRAP><FONT SIZE=2><A HREF=\"view.php?id=$log->course\">".$courses[$log->course]."</A></TD>";
}
echo "<TD NOWRAP ALIGN=right><FONT SIZE=2>".userdate($log->time, "%A")."</TD>";
echo "<TD NOWRAP><FONT SIZE=2>".userdate($log->time, "%e %B %Y, %I:%M %p")."</TD>";
echo "<TD NOWRAP><FONT SIZE=2>".userdate($log->time, "%d %B %Y, %I:%M %p")."</TD>";
echo "<TD NOWRAP><FONT SIZE=2>";
link_to_popup_window("$CFG->wwwroot/lib/ipatlas/plot.php?address=$log->ip&user=$log->user", "ipatlas","$log->ip", 400, 700);
echo "</TD>";
@@ -172,10 +175,28 @@ function print_log($course, $user=0, $date=0, $order="ORDER BY l.time ASC") {
}
function print_all_courses($cat=1, $style="full", $maxcount=999) {
global $CFG;
function print_all_courses($category="all", $style="full", $maxcount=999, $width=180) {
global $CFG, $USER;
if ($courses = get_records("course", "category", $cat, "fullname ASC")) {
if ($category == "all") {
$courses = get_records_sql("SELECT * FROM course WHERE category > 0 ORDER BY fullname ASC");
} else if ($category == "my") {
if (isset($USER->id)) {
if ($courses = get_records_sql("SELECT * FROM course WHERE category > 0 ORDER BY fullname ASC")) {
foreach ($courses as $key => $course) {
if (!isteacher($course->id) and !isstudent($course->id)) {
unset($courses[$key]);
}
}
}
}
} else {
$courses = get_records("course", "category", $category, "fullname ASC");
}
if ($courses) {
if ($style == "minimal") {
$count = 0;
$icon = "<IMG SRC=\"pix/i/course.gif\" HEIGHT=16 WIDTH=16 ALT=\"".get_string("course")."\">";
@@ -187,7 +208,7 @@ function print_all_courses($cat=1, $style="full", $maxcount=999) {
}
}
$fulllist = "<P><A HREF=\"$CFG->wwwroot/course/\">".get_string("fulllistofcourses")."</A>...";
print_side_block("", $moddata, "$fulllist", $modicon);
print_side_block(get_string("courses"), "", $moddata, $modicon, $fulllist, $width);
} else {
foreach ($courses as $course) {
@@ -221,18 +242,23 @@ function print_course($course) {
echo "<P><FONT SIZE=1>\n";
foreach ($teachers as $teacher) {
if ($teacher->authority > 0) {
echo "$course->teacher: <A HREF=\"$CFG->wwwroot/user/view.php?id=$teacher->id&course=$site->id\">$teacher->firstname $teacher->lastname</A><BR>";
if (!$teacher->role) {
$teacher->role = $course->teacher;
}
echo "$teacher->role: <A HREF=\"$CFG->wwwroot/user/view.php?id=$teacher->id&course=$site->id\">$teacher->firstname $teacher->lastname</A><BR>";
}
}
echo "</FONT></P>";
}
if ($course->guest or ($course->password == "")) {
echo "<A TITLE=\"".get_string("allowguests")."\" HREF=\"$CFG->wwwroot/course/view.php?id=$course->id\">";
echo "<IMG VSPACE=4 ALT=\"\" HEIGHT=16 WIDTH=16 BORDER=0 SRC=\"$CFG->wwwroot/user/user.gif\"></A>&nbsp;&nbsp;";
if ($course->guest) {
$strallowguests = get_string("allowguests");
echo "<A TITLE=\"$strallowguests\" HREF=\"$CFG->wwwroot/course/view.php?id=$course->id\">";
echo "<IMG VSPACE=4 ALT=\"$strallowguests\" HEIGHT=16 WIDTH=16 BORDER=0 SRC=\"$CFG->wwwroot/user/user.gif\"></A>&nbsp;&nbsp;";
}
if ($course->password) {
echo "<A TITLE=\"".get_string("requireskey")."\" HREF=\"$CFG->wwwroot/course/view.php?id=$course->id\">";
echo "<IMG VSPACE=4 ALT=\"\" HEIGHT=16 WIDTH=16 BORDER=0 SRC=\"$CFG->wwwroot/pix/i/key.gif\"></A>";
$strrequireskey = get_string("requireskey");
echo "<A TITLE=\"$strrequireskey\" HREF=\"$CFG->wwwroot/course/view.php?id=$course->id\">";
echo "<IMG VSPACE=4 ALT=\"$strrequireskey\" HEIGHT=16 WIDTH=16 BORDER=0 SRC=\"$CFG->wwwroot/pix/i/key.gif\"></A>";
}
@@ -263,7 +289,7 @@ function print_recent_activity($course) {
} else {
echo "<P ALIGN=CENTER><FONT SIZE=1>";
echo get_string("yourlastlogin").":<BR>";
echo userdate($USER->lastlogin, "%A, %e %b %Y, %H:%M");
echo userdate($USER->lastlogin, "%A, %d %b %Y, %H:%M");
echo "</FONT></P>";
}
@@ -284,7 +310,9 @@ function print_recent_activity($course) {
$content = true;
}
$user = get_record("user", "id", $log->info);
echo "<P><FONT SIZE=1><A HREF=\"../user/view.php?id=$user->id&course=$course->id\">$user->firstname $user->lastname</A></FONT></P>";
if (isstudent($course->id, $user->id)) {
echo "<P><FONT SIZE=1><A HREF=\"../user/view.php?id=$user->id&course=$course->id\">$user->firstname $user->lastname</A></FONT></P>";
}
}
}
@@ -336,85 +364,64 @@ function print_recent_activity($course) {
}
// Now all we need to know are the new posts.
// Now display new things from each module
$heading = false;
foreach ($logs as $log) {
if ($log->module == "forum") {
$post = NULL;
$mods = get_list_of_plugins("mod");
if ($log->action == "add post") {
$post = get_record_sql("SELECT p.*, d.forum, u.firstname, u.lastname,
u.email, u.picture, u.id as userid
FROM forum_discussions d, forum_posts p, user u
WHERE p.id = '$log->info' AND d.id = p.discussion AND p.user = u.id");
} else if ($log->action == "add discussion") {
$post = get_record_sql("SELECT p.*, d.forum, u.firstname, u.lastname,
u.email, u.picture, u.id as userid
FROM forum_discussions d, forum_posts p, user u
WHERE d.id = '$log->info' AND d.firstpost = p.id AND p.user = u.id");
foreach ($mods as $mod) {
include_once("$CFG->dirroot/mod/$mod/lib.php");
$print_recent_activity = $mod."_print_recent_activity";
if (function_exists($print_recent_activity)) {
$modcontent = $print_recent_activity($logs, isteacher($course->id));
if ($modcontent) {
$content = true;
}
if ($post) {
$teacherpost = "";
if ($forum = get_record("forum", "id", $post->forum) ) {
if ($forum->type == "teacher") {
if (!isteacher($course->id)) {
continue;
} else {
$teacherpost = "COLOR=$COURSE_TEACHER_COLOR";
}
}
}
if (! $heading) {
print_headline(get_string("newforumposts").":");
$heading = true;
$content = true;
}
$date = userdate($post->modified, "%e %b, %H:%M");
echo "<P><FONT SIZE=1 $teacherpost>$date - $post->firstname $post->lastname<BR>";
echo "\"<A HREF=\"$CFG->wwwroot/mod/forum/$log->url\">";
if ($log->action == "add") {
echo "<B>$post->subject</B>";
} else {
echo "$post->subject";
}
echo "</A>\"</FONT></P>";
}
}
}
if (! $content) {
echo "<FONT SIZE=2>".get_string("nothingnew")."</FONT>";
}
}
function unenrol_student_in_course($user, $course) {
global $db;
function get_array_of_activities($courseid) {
// For a given course, returns an array of course activity objects
// Each item in the array contains he following properties:
// cm - course module id
// mod - name of the module (eg forum)
// section - the number of the section (eg week or topic)
// name - the name of the instance
return $db->Execute("DELETE FROM user_students WHERE user = '$user' AND course = '$course'");
$mod = array();
if (!$rawmods = get_records_sql("SELECT cm.*, m.name as modname
FROM modules m, course_modules cm
WHERE cm.course = '$courseid'
AND cm.deleted = '0'
AND cm.module = m.id ") ) {
return NULL;
}
if ($sections = get_records("course_sections", "course", $courseid, "section ASC")) {
foreach ($sections as $section) {
if ($section->sequence) {
$sequence = explode(",", $section->sequence);
foreach ($sequence as $seq) {
$mod[$seq]->cm = $rawmods[$seq]->id;
$mod[$seq]->mod = $rawmods[$seq]->modname;
$mod[$seq]->section = $section->section;
$mod[$seq]->name = urlencode(get_field($rawmods[$seq]->modname, "name", "id", $rawmods[$seq]->instance));
}
}
}
}
return $mod;
}
function enrol_student_in_course($user, $course) {
global $db;
$timenow = time();
$rs = $db->Execute("INSERT INTO user_students (user, course, start, end, time)
VALUES ($user, $course, 0, 0, $timenow)");
if ($rs) {
return true;
} else {
return false;
}
}
function get_all_mods($courseid, &$mods, &$modnames, &$modnamesplural, &$modnamesused) {
// Returns a number of useful structures for course displays
@@ -456,9 +463,48 @@ function get_all_sections($courseid) {
ORDER BY section");
}
function print_section($courseid, $section, $mods, $modnamesused, $absolute=false, $width="100%") {
function get_all_categories() {
return get_records_sql("SELECT * FROM course_categories ORDER by name");
}
function print_section_block($heading, $course, $section, $mods, $modnames, $modnamesused,
$absolute=true, $width="100%", $isediting=false) {
global $CFG;
$modinfo = unserialize($course->modinfo);
$moddata = array();
$modicon = array();
$editbuttons = "";
if ($section->sequence) {
$sectionmods = explode(",", $section->sequence);
foreach ($sectionmods as $modnumber) {
$mod = $mods[$modnumber];
if ($isediting) {
$editbuttons = make_editing_buttons($mod->id, $absolute);
}
$instancename = urldecode($modinfo[$modnumber]->name);
$modicon[] = "<img src=\"$CFG->wwwroot/mod/$mod->modname/icon.gif\" height=\"16\" width=\"16\" alt=\"$mod->modfullname\">";
$moddata[] = "<a title=\"$mod->modfullname\" href=\"$CFG->wwwroot/mod/$mod->modname/view.php?id=$mod->id\">$instancename</a><BR>$editbuttons";
}
}
if (isediting($site->id)) {
$editmenu = popup_form("$CFG->wwwroot/course/mod.php?id=$course->id&section=0&add=",
$modnames, "section0", "", get_string("add")."...", "mods", get_string("activities"), true);
$editmenu = "<DIV ALIGN=right>$editmenu</DIV>";
}
print_side_block($heading, "", $moddata, $modicon, $editmenu, $width);
}
function print_section($course, $section, $mods, $modnamesused, $absolute=false, $width="100%") {
global $CFG;
$modinfo = unserialize($course->modinfo);
echo "<TABLE WIDTH=\"$width\"><TR><TD>\n";
if ($section->sequence) {
@@ -467,11 +513,12 @@ function print_section($courseid, $section, $mods, $modnamesused, $absolute=fals
foreach ($sectionmods as $modnumber) {
$mod = $mods[$modnumber];
$instancename = get_field("$mod->modname", "name", "id", "$mod->instance");
$instancename = urldecode($modinfo[$modnumber]->name);
echo "<IMG SRC=\"$CFG->wwwroot/mod/$mod->modname/icon.gif\" HEIGHT=16 WIDTH=16 ALT=\"$mod->modfullname\">";
echo " <FONT SIZE=2><A TITLE=\"$mod->modfullname\"";
echo " HREF=\"$CFG->wwwroot/mod/$mod->modname/view.php?id=$mod->id\">$instancename</A></FONT>";
if (isediting($courseid)) {
if (isediting($course->id)) {
echo "&nbsp;&nbsp;";
echo make_editing_buttons($mod->id, $absolute);
}
echo "<BR>\n";
@@ -480,86 +527,224 @@ function print_section($courseid, $section, $mods, $modnamesused, $absolute=fals
echo "</TD></TR></TABLE><BR>\n\n";
}
function print_side_block($heading="", $list=NULL, $footer="", $icons=NULL, $width=180) {
echo "<TABLE WIDTH=\"$width\">\n";
echo "<TR><TD COLSPAN=2><P><B><FONT SIZE=2>$heading</TD></TR>\n";
if ($list) {
foreach($list as $key => $string) {
echo "<TR><TD VALIGN=top WIDTH=12>";
if ($icons[$key]) {
echo $icons[$key];
} else {
echo "";
}
echo "</TD>\n<TD WIDTH=100% VALIGN=top>";
echo "<P><FONT SIZE=2>$string</FONT></P>";
echo "</TD></TR>\n";
}
}
if ($footer) {
echo "<TR><TD></TD><TD ALIGN=left><P><FONT SIZE=2>$footer</TD></TR>\n";
}
echo "</TABLE><BR>\n\n";
function print_heading_block($heading, $width="100%", $class="headingblock") {
global $THEME;
echo "<table width=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"5\">";
echo "<tr><td bgcolor=\"$THEME->cellheading\" class=\"$class\">";
echo stripslashes($heading);
echo "</td></tr></table>";
}
function print_side_block($heading="", $content="", $list=NULL, $icons=NULL, $footer="", $width=180) {
// Prints a nice side block with an optional header. The content can either
// be a block of HTML or a list of text with optional icons.
global $THEME;
print_side_block_start($heading, $width);
if ($content) {
echo "$content";
} else {
echo "<table width=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"2\">";
foreach ($list as $key => $string) {
echo "<tr bgcolor=\"$THEME->cellcontent2\">";
if ($icons) {
echo "<td class=\"sideblocklinks\" valign=\"top\" width=\"16\">".$icons[$key]."</td>";
}
echo "<td class=\"sideblocklinks\" valign=\"top\" width=\"*\"><font size=\"-1\">$string</font></td>";
echo "</tr>";
}
if ($footer) {
echo "<tr bgcolor=\"$THEME->cellcontent2\">";
if ($icons) {
echo "<td class=\"sideblocklinks\" valign=\"top\" width=\"16\">&nbsp;</td>";
}
echo "<td class=\"sideblocklinks\"><font size=\"-1\">$footer</td>";
echo "</tr>";
}
echo "</table>";
}
print_side_block_end();
}
function print_side_block_start($heading="", $width=180, $class="sideblockmain") {
// Starts a nice side block with an optional header.
global $THEME;
echo "<table class=\"sideblock\" width=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"5\">";
if ($heading) {
echo "<tr>";
echo "<td class=\"sideblockheading\" bgcolor=\"$THEME->cellheading\">$heading</td>";
echo "</tr>";
}
echo "<tr>";
echo "<td class=\"$class\" bgcolor=\"$THEME->cellcontent2\">";
}
function print_side_block_end() {
echo "</td></tr>";
echo "</table><br \>";
}
function print_admin_links ($siteid, $width=180) {
global $THEME, $CFG;
print_simple_box(get_string("administration"), $align="CENTER", $width, $color="$THEME->cellheading");
$icon = "<IMG SRC=\"$CFG->wwwroot/pix/i/settings.gif\" HEIGHT=16 WIDTH=16 ALT=\"\">";
$moddata[]="<A HREF=\"$CFG->wwwroot/course/log.php?id=$siteid\">".get_string("sitelogs")."</A>";
$moddata[]="<A HREF=\"$CFG->wwwroot/admin/config.php\">".get_string("configvariables")."</A>";
$modicon[]=$icon;
$moddata[]="<A HREF=\"$CFG->wwwroot/admin/site.php\">".get_string("sitesettings")."</A>";
$modicon[]=$icon;
$moddata[]="<A HREF=\"$CFG->wwwroot/course/log.php?id=$siteid\">".get_string("sitelogs")."</A>";
$modicon[]=$icon;
$moddata[]="<A HREF=\"$CFG->wwwroot/theme/index.php\">".get_string("choosetheme")."</A>";
$modicon[]=$icon;
$moddata[]="<A HREF=\"$CFG->wwwroot/admin/lang.php\">".get_string("checklanguage")."</A>";
$modicon[]=$icon;
if (file_exists("$CFG->dirroot/admin/$CFG->dbtype")) {
$moddata[]="<A HREF=\"$CFG->wwwroot/admin/$CFG->dbtype/\">".get_string("managedatabase")."</A>";
$modicon[]=$icon;
}
$moddata[]="<HR>";
$modicon[]="";
$moddata[]="<A HREF=\"$CFG->wwwroot/course/edit.php\">".get_string("addnewcourse")."</A>";
$modicon[]=$icon;
$moddata[]="<A HREF=\"$CFG->wwwroot/course/categories.php\">".get_string("categories")."</A>";
$modicon[]=$icon;
$moddata[]="<A HREF=\"$CFG->wwwroot/course/teacher.php\">".get_string("assignteachers")."</A>";
$modicon[]=$icon;
$moddata[]="<A HREF=\"$CFG->wwwroot/course/delete.php\">".get_string("deletecourse")."</A>";
$modicon[]=$icon;
$moddata[]="<HR>";
$modicon[]="";
$moddata[]="<A HREF=\"$CFG->wwwroot/admin/user.php?newuser=true\">".get_string("addnewuser")."</A>";
$modicon[]=$icon;
$moddata[]="<A HREF=\"$CFG->wwwroot/admin/user.php\">".get_string("edituser")."</A>";
$modicon[]=$icon;
$moddata[]="<A HREF=\"$CFG->wwwroot/admin/auth.php\">".get_string("authentication")."</A>";
$modicon[]=$icon;
$fulladmin = "<P><A HREF=\"$CFG->wwwroot/admin/\">".get_string("admin")."</A>...";
print_side_block("", $moddata, "$fulladmin", $modicon, $width);
print_side_block(get_string("administration"), "", $moddata, $modicon, $fulladmin, $width);
echo "<IMG SRC=\"$CFG->wwwroot/pix/spacer.gif\" WIDTH=\"$width\" HEIGHT=1><BR>";
}
function print_course_admin_links($courseid, $width=180) {
function print_course_admin_links($course, $width=180) {
global $THEME, $CFG;
echo "<BR>";
$adminicon[]="<IMG SRC=\"$CFG->wwwroot/pix/i/edit.gif\" HEIGHT=16 WIDTH=16 ALT=\"\">";
if (isediting($courseid)) {
$admindata[]="<A HREF=\"view.php?id=$courseid&edit=off\">".get_string("turneditingoff")."</A>";
if (isediting($course->id)) {
$admindata[]="<A HREF=\"view.php?id=$course->id&edit=off\">".get_string("turneditingoff")."</A>";
} else {
$admindata[]="<A HREF=\"view.php?id=$courseid&edit=on\">".get_string("turneditingon")."</A>";
$admindata[]="<A HREF=\"view.php?id=$course->id&edit=on\">".get_string("turneditingon")."</A>";
}
$admindata[]="<A HREF=\"edit.php?id=$courseid\">".get_string("settings")."...</A>";
$admindata[]="<A HREF=\"edit.php?id=$course->id\">".get_string("settings")."...</A>";
$adminicon[]="<IMG SRC=\"$CFG->wwwroot/pix/i/settings.gif\" HEIGHT=16 WIDTH=16 ALT=\"\">";
$admindata[]="<A HREF=\"log.php?id=$courseid\">".get_string("logs")."...</A>";
if (!$course->teachers) {
$course->teachers = get_string("defaultcourseteachers");
}
$admindata[]="<A HREF=\"teachers.php?id=$course->id\">$course->teachers...</A>";
$adminicon[]="<IMG SRC=\"$CFG->wwwroot/pix/i/settings.gif\" HEIGHT=16 WIDTH=16 ALT=\"\">";
$admindata[]="<A HREF=\"grades.php?id=$course->id\">".get_string("grades")."...</A>";
$adminicon[]="<IMG SRC=\"$CFG->wwwroot/pix/i/grades.gif\" HEIGHT=16 WIDTH=16 ALT=\"\">";
$admindata[]="<A HREF=\"log.php?id=$course->id\">".get_string("logs")."...</A>";
$adminicon[]="<IMG SRC=\"$CFG->wwwroot/pix/i/log.gif\" HEIGHT=16 WIDTH=16 ALT=\"\">";
$admindata[]="<A HREF=\"$CFG->wwwroot/files/index.php?id=$courseid\">".get_string("files")."...</A>";
$admindata[]="<A HREF=\"$CFG->wwwroot/files/index.php?id=$course->id\">".get_string("files")."...</A>";
$adminicon[]="<IMG SRC=\"$CFG->wwwroot/files/pix/files.gif\" HEIGHT=16 WIDTH=16 ALT=\"\">";
$admindata[]="<A HREF=\"$CFG->wwwroot/doc/view.php?id=$courseid&file=teacher.html\">".get_string("help")."...</A>";
$adminicon[]="<IMG SRC=\"$CFG->wwwroot/mod/reading/icon.gif\" HEIGHT=16 WIDTH=16 ALT=\"\">";
$admindata[]="<A HREF=\"$CFG->wwwroot/doc/view.php?id=$course->id&file=teacher.html\">".get_string("help")."...</A>";
$adminicon[]="<IMG SRC=\"$CFG->wwwroot/mod/resource/icon.gif\" HEIGHT=16 WIDTH=16 ALT=\"\">";
if ($teacherforum = forum_get_course_forum($courseid, "teacher")) {
$admindata[]="<A HREF=\"$CFG->wwwroot/mod/forum/view.php?f=$teacherforum->id\">".get_string("teacherforum")."</A>";
if ($teacherforum = forum_get_course_forum($course->id, "teacher")) {
$admindata[]="<A HREF=\"$CFG->wwwroot/mod/forum/view.php?f=$teacherforum->id\">".get_string("nameteacher", "forum")."</A>";
$adminicon[]="<IMG SRC=\"$CFG->wwwroot/mod/forum/icon.gif\" HEIGHT=16 WIDTH=16 ALT=\"\">";
}
print_simple_box(get_string("administration"), $align="CENTER", $width, $color="$THEME->cellheading");
print_side_block("", $admindata, "", $adminicon, $width);
print_side_block(get_string("administration"), "", $admindata, $adminicon, "", $width);
}
function print_course_categories($categories, $selected="none", $width=180) {
global $CFG, $THEME, $USER;
$strallowguests = get_string("allowguests");
$strrequireskey = get_string("requireskey");
if ($selected == "index") { // Print comprehensive index of categories with courses
if ($courses = get_records_sql("SELECT * FROM course WHERE category > 0 ORDER BY shortname")) {
if (isset($USER->id) and !isadmin()) {
print_simple_box_start("CENTER", "100%", $THEME->cellheading);
print_heading("<A HREF=\"course/index.php?category=my\">".get_string("mycourses")."</A>", "LEFT");
$some = false;
echo "<UL>";
foreach ($courses as $key => $course) {
if (isteacher($course->id) or isstudent($course->id)) {
echo "<A HREF=\"$CFG->wwwroot/course/view.php?id=$course->id\">$course->fullname</A>";
echo "<BR>";
$some = true;
}
}
if (!$some) {
print_string("nocoursesyet");
}
echo "</UL>";
print_simple_box_end();
print_spacer(8,1);
}
foreach ($categories as $category) {
print_simple_box_start("CENTER", "100%");
print_heading("<A HREF=\"course/index.php?category=$category->id\">$category->name</A>", "LEFT");
$some = false;
echo "<UL>";
foreach ($courses as $key => $course) {
if ($course->category == $category->id) {
echo "<A HREF=\"$CFG->wwwroot/course/view.php?id=$course->id\">$course->fullname</A>";
echo "&nbsp;&nbsp;";
unset($courses[$key]);
if ($course->guest ) {
echo "<A TITLE=\"$strallowguests\" HREF=\"$CFG->wwwroot/course/view.php?id=$course->id\">";
echo "<IMG ALT=\"\" HEIGHT=16 WIDTH=16 BORDER=0 SRC=\"$CFG->wwwroot/user/user.gif\"></A>";
}
if ($course->password) {
echo "<A TITLE=\"$strrequireskey\" HREF=\"$CFG->wwwroot/course/view.php?id=$course->id\">";
echo "<IMG ALT=\"\" HEIGHT=16 WIDTH=16 BORDER=0 SRC=\"$CFG->wwwroot/pix/i/key.gif\"></A>";
}
echo "<BR>";
$some = true;
}
}
if (!$some) {
print_string("nocoursesyet");
}
echo "</UL>";
print_simple_box_end();
print_spacer(8,1);
}
}
} else { // Print short list of categories only
foreach ($categories as $cat) {
$caticon[]="<IMG SRC=\"$CFG->wwwroot/pix/i/course.gif\" HEIGHT=16 WIDTH=16>";
if ($cat->id == $selected) {
$catdata[]="$cat->name";
} else {
$catdata[]="<A HREF=\"$CFG->wwwroot/course/index.php?category=$cat->id\">$cat->name</A>";
}
}
$catdata[] = "<A HREF=\"$CFG->wwwroot/course/index.php?category=all\">".get_string("fulllistofcourses")."</A>";
if (isset($USER->id)) {
$catdata[] = "<A HREF=\"$CFG->wwwroot/course/index.php?category=my\">".get_string("mycourses")."</A>";
}
print_side_block(get_string("categories"), "", $catdata, $caticon, $showall.$mine, $width);
}
}
function print_log_graph($course, $userid=0, $type="course.png", $date=0) {
global $CFG;
@@ -573,60 +758,35 @@ function print_log_graph($course, $userid=0, $type="course.png", $date=0) {
function add_course_module($mod) {
GLOBAL $db;
$timenow = time();
if (!$rs = $db->Execute("INSERT into course_modules
SET course = '$mod->course',
module = '$mod->module',
instance = '$mod->instance',
section = '$mod->section',
added = '$timenow' ")) {
return 0;
}
// Get it out again - this is the most compatible way to determine the ID
if ($rs = $db->Execute("SELECT id FROM course_modules
WHERE module = $mod->module AND added = $timenow")) {
return $rs->fields[0];
} else {
return 0;
}
$mod->added = time();
return insert_record("course_modules", $mod);
}
function add_mod_to_section($mod) {
// Returns the course_sections ID where the mod is inserted
GLOBAL $db;
if ($cw = get_record_sql("SELECT * FROM course_sections
WHERE course = '$mod->course' AND section = '$mod->section'") ) {
if ($section = get_record_sql("SELECT * FROM course_sections
WHERE course = '$mod->course' AND section = '$mod->section'") ) {
if ($cw->sequence) {
$newsequence = "$cw->sequence,$mod->coursemodule";
if ($section->sequence) {
$newsequence = "$section->sequence,$mod->coursemodule";
} else {
$newsequence = "$mod->coursemodule";
}
if (!$rs = $db->Execute("UPDATE course_sections SET sequence = '$newsequence' WHERE id = '$cw->id'")) {
return 0;
if (set_field("course_sections", "sequence", $newsequence, "id", $section->id)) {
return $section->id; // Return course_sections ID that was used.
} else {
return $cw->id; // Return course_sections ID that was used.
return 0;
}
} else { // Insert a new record
if (!$rs = $db->Execute("INSERT into course_sections
SET course = '$mod->course',
section = '$mod->section',
summary = '',
sequence = '$mod->coursemodule' ")) {
return 0;
}
// Get it out again - this is the most compatible way to determine the ID
if ($rs = $db->Execute("SELECT id FROM course_sections
WHERE course = '$mod->course' AND section = '$mod->section'")) {
return $rs->fields[0];
} else {
return 0;
}
$section->course = $mod->course;
$section->section = $mod->section;
$section->summary = "";
$section->sequence = $mod->coursemodule;
return insert_record("course_sections", $section);
}
}
@@ -637,14 +797,14 @@ function delete_course_module($mod) {
function delete_mod_from_section($mod, $section) {
GLOBAL $db;
if ($cw = get_record("course_sections", "id", "$section") ) {
if ($section = get_record("course_sections", "id", "$section") ) {
$modarray = explode(",", $cw->sequence);
$modarray = explode(",", $section->sequence);
if ($key = array_keys ($modarray, $mod)) {
array_splice($modarray, $key[0], 1);
$newsequence = implode(",", $modarray);
return set_field("course_sections", "sequence", $newsequence, "id", $cw->id);
return set_field("course_sections", "sequence", $newsequence, "id", $section->id);
} else {
return false;
}
@@ -655,17 +815,13 @@ function delete_mod_from_section($mod, $section) {
}
function move_module($id, $move) {
function move_module($cm, $move) {
GLOBAL $db;
if (!$move) {
return true;
}
if (! $cm = get_record("course_modules", "id", $id)) {
error("This course module doesn't exist");
}
if (! $thissection = get_record("course_sections", "id", $cm->section)) {
error("This course section doesn't exist");
}
@@ -796,8 +952,7 @@ function make_editing_buttons($moduleid, $absolute=false) {
} else {
$path = "";
}
return "&nbsp; &nbsp;
<A TITLE=\"$delete\" HREF=\"".$path."mod.php?delete=$moduleid\"><IMG
return "<A TITLE=\"$delete\" HREF=\"".$path."mod.php?delete=$moduleid\"><IMG
SRC=".$path."../pix/t/delete.gif BORDER=0></A>
<A TITLE=\"$moveup\" HREF=\"".$path."mod.php?id=$moduleid&move=-1\"><IMG
SRC=".$path."../pix/t/up.gif BORDER=0></A>
+1 -1
View File
@@ -39,7 +39,7 @@
$userinfo = "$u->firstname $u->lastname";
}
if ($date) {
$dateinfo = userdate($date, "%A, %e %B %Y");
$dateinfo = userdate($date, "%A, %d %B %Y");
}
print_header("$course->shortname: $strlogs", "$course->fullname",
+27 -5
View File
@@ -40,10 +40,24 @@
}
$timestart = $coursestart = usergetmidnight($course->startdate);
if ((($timenow - $timestart)/86400.0) > 40) {
$reducedays = 7;
} else {
$reducedays = 0;
}
$i = 0;
while ($timestart < $timenow) {
$timefinish = $timestart + 86400;
$days[$i] = userdate($timestart, "%a %e %b");
if ($reducedays) {
if ($i % $reducedays) {
$days[$i] = "";
} else {
$days[$i] = userdate($timestart, "%a %d %b");
}
} else {
$days[$i] = userdate($timestart, "%a %d %b");
}
$logs[$i] = 0;
$i++;
$timestart = $timefinish;
@@ -64,13 +78,16 @@
$graph = new graph(750, 400);
$graph->parameter['title'] = "Hits on $course->shortname by $user->firstname $user->lastname";
$a->coursename = $course->shortname;
$a->username = "$user->firstname $user->lastname";
$graph->parameter['title'] = get_string("hitsoncourse", "", $a);
$graph->x_data = $days;
$graph->y_data['logs'] = $logs;
$graph->y_format['logs'] = array('colour' => 'blue','line' => 'line');
$graph->y_label_left = "Hits";
$graph->y_label_left = get_string("hits");
$graph->label_size = "6";
$graph->y_order = array('logs');
@@ -78,6 +95,7 @@
$graph->parameter['shadow'] = 'none';
error_reporting(5); // ignore most warnings such as font problems etc
$graph->draw_stack();
break;
@@ -112,13 +130,16 @@
$maxlogs = max($logs);
$graph = new graph(750, 400);
$graph->parameter['title'] = "Today's hits on $course->shortname by $user->firstname $user->lastname";
$a->coursename = $course->shortname;
$a->username = "$user->firstname $user->lastname";
$graph->parameter['title'] = get_string("hitsoncoursetoday", "", $a);
$graph->x_data = $hours;
$graph->y_data['logs'] = $logs;
$graph->y_format['logs'] = array('colour' => 'blue','bar' => 'fill','legend' =>'actual','bar_size' => 0.9);
$graph->y_label_left = "Hits";
$graph->y_label_left = get_string("hits");
$graph->label_size = "6";
$graph->y_order = array('logs');
@@ -126,6 +147,7 @@
$graph->parameter['shadow'] = 'none';
error_reporting(5); // ignore most warnings such as font problems etc
$graph->draw_stack();
break;
+14 -1
View File
@@ -5,7 +5,8 @@
require("lib.php");
require_variable($id); // course id
require_variable($user); // login as this user
optional_variable($user); // login as this user
optional_variable($return); // return to being the real user again
if (! $course = get_record("course", "id", $id)) {
error("Course ID was incorrect");
@@ -13,6 +14,17 @@
require_login($course->id);
if ($return and $USER->realuser) {
$USER = get_user_info_from_db("id", $USER->realuser);
$USER->loggedin = true;
$USER->site = $CFG->wwwroot;
save_session("USER");
redirect($HTTP_REFERER);
exit;
}
// $user must be defined to go on
if (!isteacher($course->id)) {
error("Only teachers can use this page!");
}
@@ -28,6 +40,7 @@
$USER = get_user_info_from_db("id", $user);
$USER->loggedin = true;
$USER->site = $CFG->wwwroot;
$USER->realuser = $teacher_id;
save_session("USER");
+46 -7
View File
@@ -5,8 +5,27 @@
require("../config.php");
require("lib.php");
if (isset($cancel)) {
if ($SESSION->returnpage) {
$return = $SESSION->returnpage;
unset($SESSION->returnpage);
save_session("SESSION");
redirect($return);
} else {
redirect("view.php?id=$mod->course");
}
}
if (isset($course) && isset($HTTP_POST_VARS)) { // add or update form submitted
$mod = (object)$HTTP_POST_VARS;
if (isset($SESSION->modform)) { // Variables are stored in the session
$mod = $SESSION->modform;
unset($SESSION->modform);
save_session("SESSION");
} else {
$mod = (object)$HTTP_POST_VARS;
}
require_login($mod->course);
@@ -67,6 +86,11 @@
}
$modinfo = serialize(get_array_of_activities($mod->course));
if (!set_field("course", "modinfo", $modinfo, "id", $mod->course)) {
error("Could not cache module information!");
}
if ($SESSION->returnpage) {
$return = $SESSION->returnpage;
unset($SESSION->returnpage);
@@ -78,16 +102,21 @@
exit;
}
if (isset($return)) {
$SESSION->returnpage = $HTTP_REFERER;
save_session("SESSION");
}
if (isset($move)) {
require_variable($id);
move_module($id, $move);
if (! $cm = get_record("course_modules", "id", $id)) {
error("This course module doesn't exist");
}
move_module($cm, $move);
$modinfo = serialize(get_array_of_activities($cm->course));
if (!set_field("course", "modinfo", $modinfo, "id", $cm->course)) {
error("Could not cache module information!");
}
redirect($HTTP_REFERER);
exit;
@@ -161,6 +190,11 @@
error("This course section doesn't exist");
}
if (isset($return)) {
$SESSION->returnpage = "$CFG->wwwroot/mod/$module->name/view.php?id=$cm->id";
save_session("SESSION");
}
$form->coursemodule = $cm->id;
$form->section = $cm->section; // The section ID
$form->course = $course->id;
@@ -228,16 +262,21 @@
}
$streditinga = get_string("editinga", "moodle", $fullmodulename);
$strmodulenameplural = get_string("modulenameplural", $module->name);
if ($course->category) {
print_header("$course->shortname: $streditinga", "$course->fullname",
"<A HREF=\"$CFG->wwwroot/course/view.php?id=$course->id\">$course->shortname</A> ->
<A HREF=\"$CFG->wwwroot/mod/$module->name/index.php?id=$course->id\">$strmodulenameplural</A> ->
$streditinga", "form.name", "", false);
} else {
print_header("$course->shortname: $streditinga", "$course->fullname",
"$streditinga", "form.name", "", false);
}
unset($SESSION->modform); // Clear any old ones that may be hanging around.
save_session("SESSION");
$modform = "../mod/$module->name/mod.html";
if (file_exists($modform)) {
@@ -248,7 +287,7 @@
print_simple_box_end();
} else {
notice("This module cannot be added to this course yet!", "$CFG->wwwroot/course/view.php?id=$course->id");
notice("This module cannot be added to this course yet! (No file found at: $modform)", "$CFG->wwwroot/course/view.php?id=$course->id");
}
print_footer($course);
+27 -33
View File
@@ -2,61 +2,57 @@
// social.php - course format featuring social forum
// included from view.php
include("../mod/forum/lib.php");
include("../mod/reading/lib.php");
include_once("$CFG->dirroot/mod/forum/lib.php");
include_once("$CFG->dirroot/mod/resource/lib.php");
$leftwidth = 210;
?>
<TABLE WIDTH="100%" BORDER="0" CELLSPACING="5" CELLPADDING="5">
<TR>
<TD WIDTH="15%" VALIGN="TOP">
<TD WIDTH="<?=$leftwidth?>" VALIGN="TOP">
<?
print_simple_box(get_string("people"), $align="CENTER", $width="100%", $color="$THEME->cellheading");
$moddata[]="<A HREF=\"../user/index.php?id=$course->id\">".get_string("listofallpeople")."</A>";
$moddata[]="<A TITLE=\"".get_string("listofallpeople")."\" HREF=\"../user/index.php?id=$course->id\">".get_string("participants")."</A>";
$modicon[]="<IMG SRC=\"../user/users.gif\" HEIGHT=16 WIDTH=16 ALT=\"\">";
$editmyprofile = "<A HREF=\"../user/view.php?id=$USER->id&course=$course->id\">".
$editmyprofile = "<A TITLE=\"$USER->firstname $USER->lastname\" HREF=\"../user/view.php?id=$USER->id&course=$course->id\">".
get_string("editmyprofile")."</A>";
if ($USER->description) {
$moddata[]= $editmyprofile;
} else {
$moddata[]= $editmyprofile.$blinker;
$moddata[]= $editmyprofile." <BLINK>*</BLINK>";
}
$modicon[]="<IMG SRC=\"../user/user.gif\" HEIGHT=16 WIDTH=16 ALT=\"\">";
print_side_block("", $moddata, "", $modicon);
print_side_block(get_string("people"), "", $moddata, $modicon, "", $leftwidth);
// Then, print all the available resources (Section 0)
print_simple_box(get_string("resources"), $align="CENTER", $width="100%", $color="$THEME->cellheading");
print_section($site->id, $sections[0], $mods, $modnamesused, true);
/// Then, print all the available resources (Section 0)
print_section_block(get_string("activities"), $course, $sections[0],
$mods, $modnames, $modnamesused, true, "100%", isediting($course->id));
if (isediting($site->id)) {
echo "<DIV ALIGN=right>";
popup_form("$CFG->wwwroot/course/mod.php?id=$course->id&section=0&add=",
$modnames, "section0", "", get_string("add")."...");
echo "</DIV>";
}
/// Print all the recent activity
// Print all the recent activity
print_simple_box(get_string("recentactivity"), $align="CENTER", $width="100%", $color="$THEME->cellheading");
echo "<TABLE CELLPADDING=4 CELLSPACING=0><TR><TD>";
print_recent_activity($course);
echo "</TD></TR></TABLE>";
echo "<BR>";
if ($course->showrecent) {
print_side_block_start(get_string("recentactivity"), $leftwidth, "sideblockrecentactivity");
print_recent_activity($course);
print_side_block_end();
}
// Print a form to search forums
print_simple_box(get_string("search","forum"), $align="CENTER", $width="100%", $color="$THEME->cellheading");
echo "<DIV ALIGN=CENTER>";
forum_print_search_form($course);
echo "</DIV>";
// Admin links and controls
/// Print a form to search forums
$searchform = forum_print_search_form($course, "", true);
$searchform = "<DIV ALIGN=\"CENTER\">$searchform</DIV>";
print_side_block(get_string("search","forum"), $searchform, "", "", "", $leftwidth);
/// Admin links and controls
if (isteacher($course->id)) {
print_course_admin_links($course->id);
print_course_admin_links($course, "100%", $leftwidth);
}
echo "</TD>";
echo "<TD WIDTH=\"55%\" VALIGN=\"TOP\">";
echo "<TD WIDTH=\"*\" VALIGN=\"TOP\">";
if ($social = forum_get_course_forum($course->id, "social")) {
if (forum_is_subscribed($USER->id, $social->id)) {
$subtext = get_string("unsubscribe", "forum");
@@ -64,12 +60,10 @@
$subtext = get_string("subscribe", "forum");
}
$headertext = "<TABLE BORDER=0 WIDTH=100% CELLPADDING=0 CELLSPACING=0><TR><TD>".get_string("socialheadline")."</TD><TD ALIGN=RIGHT><FONT SIZE=1><A HREF=\"../mod/forum/subscribe.php?id=$social->id\">$subtext</A></TD></TR></TABLE>";
print_simple_box("$headertext", $align="CENTER", $width="100%", $color="$THEME->cellheading");
print_heading_block($headertext);
echo "<IMG ALT=\"\" HEIGHT=7 SRC=\"../pix/spacer.gif\"><BR>";
forum_print_latest_discussions($social->id, 10, "plain", "DESC", false);
$SESSION->fromdiscussion = "$CFG->wwwroot/course/view.php?id=$course->id";
save_session("SESSION");
} else {
notify("Could not find or create a social forum here");
+8 -15
View File
@@ -29,7 +29,7 @@
$strtoomanytoshow = get_string("toomanytoshow");
if (!$id) {
print_header("$site->fullname: $strassignteachers", "$site->fullname",
print_header("$site->shortname: $strassignteachers", "$site->fullname",
"<A HREF=\"$CFG->wwwroot/admin\">$stradministration</A> -> $strassignteachers");
if ($courses = get_records_sql("SELECT * from course WHERE category > 0 ORDER BY fullname")) {
@@ -53,7 +53,7 @@
}
print_header("$site->fullname: $course->shortname: $strassignteachers",
print_header("$site->shortname: $course->shortname: $strassignteachers",
"$site->fullname",
"<A HREF=\"$CFG->wwwroot/admin\">$stradministration</A> ->
<A HREF=\"teacher.php\">$strassignteachers</A> ->
@@ -62,10 +62,7 @@
/// Get all existing teachers for this course.
$teachers = get_records_sql("SELECT u.*,t.authority,t.id as teachid FROM user u, user_teachers t
WHERE t.course = '$course->id'
AND t.user = u.id
ORDER BY t.authority ASC");
$teachers = get_course_teachers($course->id);
/// Add a teacher if one is specified
@@ -93,7 +90,6 @@
if (! $teacher->id) {
error("Could not add that teacher to this course!");
}
$user->authority = $teacher->authority;
$teachers[] = $user;
}
@@ -104,16 +100,13 @@
error("That teacher (id = $remove) doesn't exist", "teacher.php?id=$course->id");
}
if ($teachers) {
foreach ($teachers as $tt) {
foreach ($teachers as $key => $tt) {
if ($tt->id == $user->id) {
delete_records("user_teachers", "id", "$tt->teachid");
remove_teacher($user->id, $course->id);
unset($teachers[$key]);
}
}
}
$teachers = get_records_sql("SELECT u.*,t.authority,t.id as teachid FROM user u, user_teachers t
WHERE t.course = '$course->id'
AND t.user = u.id
ORDER BY t.authority ASC");
}
@@ -139,13 +132,13 @@
/// Print list of potential teachers
if ($search) {
$users = get_records_sql("SELECT * from user WHERE confirmed = 1
$users = get_records_sql("SELECT * from user WHERE confirmed = 1 AND deleted = 0
AND (firstname LIKE '%$search%' OR
lastname LIKE '%$search%' OR
email LIKE '%$search%')
AND username <> 'guest' AND username <> 'changeme'");
} else {
$users = get_records_sql("SELECT * from user WHERE confirmed = 1
$users = get_records_sql("SELECT * from user WHERE confirmed = 1 AND deleted = 0
AND username <> 'guest' AND username <> 'changeme'");
}
+92
View File
@@ -0,0 +1,92 @@
<?PHP // $Id$
// Allows a teacher to edit teacher order and roles for a course
require("../config.php");
require("lib.php");
require_variable($id); // course id
if (! $course = get_record("course", "id", $id)) {
error("Course ID was incorrect");
}
require_login($course->id);
if (!isteacher($course->id)) {
error("Only teachers can edit the course!");
}
/// If data submitted, then process and store.
if (match_referer() && isset($HTTP_POST_VARS)) {
$rank = array();
// Peel out all the data from variable names.
foreach ($HTTP_POST_VARS as $key => $val) {
if ($key <> "id") {
$type = substr($key,0,1);
$num = substr($key,1);
$rank[$num][$type] = $val;
}
}
foreach ($rank as $num => $vals) {
if (! $teacher = get_record_sql("SELECT * FROM user_teachers WHERE course='$course->id' and user='$num'")) {
error("No such teacher in course $course->shortname with user id $num");
}
$teacher->role = $vals[r];
$teacher->authority = $vals[a];
if (!update_record("user_teachers", $teacher)) {
error("Could not update teacher entry id = $teacher->id");
}
}
redirect("teachers.php?id=$course->id", get_string("changessaved"));
}
/// Otherwise fill and print the form.
print_header("$course->shortname: $course->teachers", "$course->fullname",
"<A HREF=\"$CFG->wwwroot/course/view.php?id=$course->id\">$course->shortname</A>
-> $course->teachers");
if (!$teachers = get_course_teachers($course->id)) {
error("No teachers found in this course!");
}
print_heading($course->teachers);
$table->head = array ("", get_string("name"), get_string("order"), get_string("role"));
$table->align = array ("RIGHT", "LEFT", "CENTER", "CENTER");
$table->size = array ("35", "", "", "");
$option[0] = get_string("hide");
for ($i=1; $i<=8; $i++) {
$option[$i] = $i;
}
echo "<FORM ACTION=teachers.php METHOD=post>";
foreach ($teachers as $teacher) {
$picture = print_user_picture($teacher->id, $course->id, $teacher->picture, false, true);
$authority = choose_from_menu ($option, "a$teacher->id", $teacher->authority, "", "", "", true);
if (!$teacher->role) {
$teacher->role = $course->teacher;
}
$table->data[] = array ($picture, "$teacher->firstname $teacher->lastname", $authority,
"<INPUT TYPE=text NAME=\"r$teacher->id\" VALUE=\"$teacher->role\" SIZE=30>");
}
print_table($table);
echo "<INPUT TYPE=hidden NAME=id VALUE=\"$course->id\">";
echo "<CENTER><BR><INPUT TYPE=submit VALUE=\"".get_string("savechanges")."\"> ";
helpbutton("teachers", $course->teachers);
echo "</CENTER>";
echo "</FORM>";
print_footer($course);
?>
+87 -51
View File
@@ -6,7 +6,7 @@
// courses that aren't so rigidly defined by time.
// Included from "view.php"
include("../mod/forum/lib.php");
include_once("$CFG->dirroot/mod/forum/lib.php");
if (! $sections = get_all_sections($course->id) ) {
$section->course = $course->id; // Create a default section.
@@ -33,33 +33,36 @@
}
}
if ($course->newsitems) {
$news = forum_get_course_forum($course->id, "news");
}
// Layout the whole page as three big columns.
$streditsummary = get_string("editsummary");
$stradd = get_string("add");
$stractivities = get_string("activities");
/// Layout the whole page as three big columns.
echo "<TABLE BORDER=0 CELLPADDING=3 CELLSPACING=0 WIDTH=100%>";
/// The left column ...
echo "<TR VALIGN=top><TD VALIGN=top WIDTH=180>";
// Layout the left column
// Links to people
$blinker = " <BLINK>*</BLINK>";
print_simple_box(get_string("people"), $align="CENTER", $width="100%", $color="$THEME->cellheading");
$moddata[]="<A HREF=\"../user/index.php?id=$course->id\">".get_string("listofallpeople")."</A>";
/// Links to people
$moddata[]="<A TITLE=\"".get_string("listofallpeople")."\" HREF=\"../user/index.php?id=$course->id\">".get_string("participants")."</A>";
$modicon[]="<IMG SRC=\"../user/users.gif\" HEIGHT=16 WIDTH=16 ALT=\"\">";
$editmyprofile = "<A HREF=\"../user/view.php?id=$USER->id&course=$course->id\">".get_string("editmyprofile")."</A>";
$editmyprofile = "<A TITLE=\"$USER->firstname $USER->lastname\" HREF=\"../user/view.php?id=$USER->id&course=$course->id\">".get_string("editmyprofile")."</A>";
if ($USER->description) {
$moddata[]= $editmyprofile;
} else {
$moddata[]= $editmyprofile.$blinker;
$moddata[]= $editmyprofile." <BLINK>*</BLINK>";
}
$modicon[]="<IMG SRC=\"../user/user.gif\" HEIGHT=16 WIDTH=16 ALT=\"\">";
print_side_block("", $moddata, "", $modicon);
print_side_block(get_string("people"), "", $moddata, $modicon);
// Then all the links to module types
/// Links to all activity modules by type
$moddata = array();
$modicon = array();
if ($modnamesused) {
@@ -68,35 +71,67 @@
$modicon[] = "<IMG SRC=\"../mod/$modname/icon.gif\" HEIGHT=16 WIDTH=16 ALT=\"\">";
}
}
print_simple_box("Activities", $align="CENTER", $width="100%", $color="$THEME->cellheading");
print_side_block("", $moddata, "", $modicon);
print_side_block($stractivities, "", $moddata, $modicon);
// Print a form to search forums
print_simple_box(get_string("search","forum"), $align="CENTER", $width="100%", $color="$THEME->cellheading");
echo "<DIV ALIGN=CENTER>";
forum_print_search_form($course);
echo "</DIV>";
/// Print a form to search forums
$searchform = forum_print_search_form($course, "", true);
$searchform = "<DIV ALIGN=\"CENTER\">$searchform</DIV>";
print_side_block(get_string("search","forum"), $searchform);
// Admin links and controls
/// Admin links and controls
if (isteacher($course->id)) {
print_course_admin_links($course->id);
print_course_admin_links($course);
}
// Start main column
/// Start main column
echo "</TD><TD WIDTH=\"*\">";
print_simple_box(get_string("topicoutline"), $align="CENTER", $width="100%", $color="$THEME->cellheading");
// Everything below uses "section" terminology - each "section" is a topic.
print_heading_block(get_string("topicoutline"), "100%", "outlineheadingblock");
print_spacer(8, 1, true);
echo "<table class=\"topicsoutline\" border=\"0\" cellpadding=\"8\" cellspacing=\"0\" width=\"100%\">";
/// Print Section 0
$topic = 0;
$thistopic = $sections[$topic];
if ($thistopic->summary or $thistopic->sequence or isediting($course->id)) {
echo "<TR>";
echo "<TD NOWRAP BGCOLOR=\"$THEME->cellheading\" VALIGN=top WIDTH=20>&nbsp;</TD>";
echo "<TD VALIGN=top BGCOLOR=\"$THEME->cellcontent\" WIDTH=\"100%\">";
if (isediting($course->id)) {
$thistopic->summary .= "&nbsp;<A TITLE=\"$streditsummary\" ".
"HREF=\"editsection.php?id=$thistopic->id\"><IMG SRC=\"../pix/t/edit.gif\" ".
"BORDER=0 ALT=\"$streditsummary\"></A></P>";
}
echo text_to_html($thistopic->summary);
print_section($course, $thistopic, $mods, $modnamesused);
if (isediting($course->id)) {
echo "<DIV ALIGN=right>";
popup_form("$CFG->wwwroot/course/mod.php?id=$course->id&section=$topic&add=",
$modnames, "section$topic", "", "$stradd...", "mods", $stractivities);
echo "</DIV>";
}
echo "</TD>";
echo "<TD NOWRAP BGCOLOR=\"$THEME->cellheading\" VALIGN=top ALIGN=CENTER WIDTH=10>&nbsp;";
echo "</TD>";
echo "</TR>";
echo "<TR><TD COLSPAN=3><IMG SRC=\"../pix/spacer.gif\" WIDTH=1 HEIGHT=1></TD></TR>";
}
/// Now all the normal modules by topic
/// Everything below uses "section" terminology - each "section" is a topic.
// Now all the sectionly modules
$timenow = time();
$section = 1;
$streditsummary = get_string("editsummary");
$stradd = get_string("add");
echo "<TABLE BORDER=0 CELLPADDING=8 CELLSPACING=0 WIDTH=100%>";
while ($section <= $course->numsections) {
if (isset($USER->topic)) { // Just display a single topic
@@ -136,12 +171,12 @@
echo text_to_html($thissection->summary);
print_section($course->id, $thissection, $mods, $modnamesused);
print_section($course, $thissection, $mods, $modnamesused);
if (isediting($course->id)) {
echo "<DIV ALIGN=right>";
popup_form("$CFG->wwwroot/course/mod.php?id=$course->id&section=$section&add=",
$modnames, "section$section", "", "$stradd...");
$modnames, "section$section", "", "$stradd...", "mods", $stractivities);
echo "</DIV>";
}
@@ -168,27 +203,28 @@
echo "</TABLE>";
echo "</TD><TD WIDTH=210>";
if ($news or $course->showrecent) {
echo "</TD><TD WIDTH=210>";
// Print all the news items.
/// Print all the news items.
if ($course->newsitems) {
if ($news = forum_get_course_forum($course->id, "news")) {
print_simple_box(get_string("latestnews"), $align="CENTER", $width="100%", $color="$THEME->cellheading");
print_simple_box_start("CENTER", "100%", "#FFFFFF", 3, 0);
echo "<FONT SIZE=1>";
if ($news) {
print_side_block_start(get_string("latestnews"), 210, "sideblocklatestnews");
echo "<FONT SIZE=\"-2\">";
forum_print_latest_discussions($news->id, $course->newsitems, "minimal", "DESC", false);
echo "</FONT>";
print_simple_box_end();
print_side_block_end();
}
// Print all the recent activity
if ($course->showrecent) {
print_side_block_start(get_string("recentactivity"), 210, "sideblockrecentactivity");
print_recent_activity($course);
print_side_block_end();
}
echo "<BR>";
}
// Print all the recent activity
print_simple_box(get_string("recentactivity"), $align="CENTER", $width="100%", $color="$THEME->cellheading");
print_simple_box_start("CENTER", "100%", "#FFFFFF", 3, 0);
print_recent_activity($course);
print_simple_box_end();
print_spacer(1, 120, true);
}
echo "</TD></TR></TABLE>\n";
+1 -4
View File
@@ -26,13 +26,10 @@
if (isset($confirm)) {
if (! unenrol_student_in_course($user->id, $course->id)) {
if (! unenrol_student($user->id, $course->id)) {
error("An error occurred while trying to unenrol you.");
}
// remove some other things
delete_records("forum_subscriptions", "user", $user->id);
add_to_log($course->id, "course", "unenrol", "view.php?id=$course->id", "$user->id");
if ($user->id == $USER->id) {
+6 -3
View File
@@ -38,13 +38,16 @@
} else if ($help == "off") {
$USER->help = false;
}
save_session("USER");
$SESSION->fromdiscussion = "$CFG->wwwroot/course/view.php?id=$course->id";
save_session("SESSION");
if (! $course->category) { // This course is not a real course.
redirect("$CFG->wwwroot");
redirect("$CFG->wwwroot/");
}
$courseword = get_string("course");
print_header("$courseword: $course->fullname", "$course->fullname", "$course->shortname", "search.search", "", true,
@@ -67,6 +70,6 @@
error("Course format not defined yet!");
}
print_footer($course);
print_footer();
?>
+89 -53
View File
@@ -2,7 +2,7 @@
// Display the whole course as "weeks" made of of modules
// Included from "view.php"
include("../mod/forum/lib.php");
include_once("$CFG->dirroot/mod/forum/lib.php");
if (! $sections = get_all_sections($course->id)) {
$section->course = $course->id; // Create a default section.
@@ -22,31 +22,36 @@
save_session("USER");
}
// Layout the whole page as three big columns.
echo "<TABLE BORDER=0 CELLPADDING=3 CELLSPACING=0 WIDTH=100%>";
echo "<TR VALIGN=top><TD VALIGN=top WIDTH=180>";
if ($course->newsitems) {
$news = forum_get_course_forum($course->id, "news");
}
// Layout the left column
$streditsummary = get_string("editsummary");
$stradd = get_string("add");
$stractivities = get_string("activities");
// Links to people
/// Layout the whole page as three big columns.
echo "<TABLE BORDER=0 CELLPADDING=3 CELLSPACING=0 WIDTH=100%>";
print_simple_box(get_string("people"), $align="CENTER", $width="100%", $color="$THEME->cellheading");
$moddata[]="<A HREF=\"../user/index.php?id=$course->id\">".get_string("listofallpeople")."</A>";
/// The left column ...
echo "<TR VALIGN=top><TD VALIGN=top WIDTH=180>";
/// Links to people
$moddata[]="<A TITLE=\"".get_string("listofallpeople")."\" HREF=\"../user/index.php?id=$course->id\">".get_string("participants")."</A>";
$modicon[]="<IMG SRC=\"../user/users.gif\" HEIGHT=16 WIDTH=16 ALT=\"\">";
$editmyprofile = "<A HREF=\"../user/view.php?id=$USER->id&course=$course->id\">".get_string("editmyprofile")."</A>";
$editmyprofile = "<A TITLE=\"$USER->firstname $USER->lastname\" HREF=\"../user/view.php?id=$USER->id&course=$course->id\">".get_string("editmyprofile")."</A>";
if ($USER->description) {
$moddata[]= $editmyprofile;
} else {
$moddata[]= $editmyprofile.$blinker;
$moddata[]= $editmyprofile." <BLINK>*</BLINK>";
}
$modicon[]="<IMG SRC=\"../user/user.gif\" HEIGHT=16 WIDTH=16 ALT=\"\">";
print_side_block("", $moddata, "", $modicon);
print_side_block(get_string("people"), "", $moddata, $modicon);
// Then all the links to module types
/// Then all the links to activities by type
$moddata = array();
$modicon = array();
if ($modnamesused) {
@@ -55,36 +60,69 @@
$modicon[] = "<IMG SRC=\"../mod/$modname/icon.gif\" HEIGHT=16 WIDTH=16 ALT=\"\">";
}
}
print_simple_box(get_string("activities"), $align="CENTER", $width="100%", $color="$THEME->cellheading");
print_side_block("", $moddata, "", $modicon);
print_side_block($stractivities, "", $moddata, $modicon);
// Print a form to search forums
print_simple_box(get_string("search","forum"), $align="CENTER", $width="100%", $color="$THEME->cellheading");
echo "<DIV ALIGN=CENTER>";
forum_print_search_form($course);
echo "</DIV>";
/// Print a form to search forums
$searchform = forum_print_search_form($course, "", true);
$searchform = "<DIV ALIGN=\"CENTER\">$searchform</DIV>";
print_side_block(get_string("search","forum"), $searchform);
// Admin links and controls
/// Admin links and controls
if (isteacher($course->id)) {
print_course_admin_links($course->id);
print_course_admin_links($course);
}
// Start main column
echo "</TD><TD WIDTH=\"*\">";
print_simple_box(get_string("weeklyoutline"), $align="CENTER", $width="100%", $color="$THEME->cellheading");
/// Start main column
echo "</TD><TD WIDTH=\"*\">";
print_heading_block(get_string("weeklyoutline"), "100%", "outlineheadingblock");
print_spacer(8, 1, true);
echo "<table class=\"weeklyoutline\" border=\"0\" cellpadding=\"8\" cellspacing=\"0\" width=\"100%\">";
/// Print Week 0 with general activities
$week = 0;
$thisweek = $sections[$week];
if ($thisweek->summary or $thisweek->sequence or isediting($course->id)) {
echo "<TR>";
echo "<TD NOWRAP BGCOLOR=\"$THEME->cellheading\" VALIGN=top WIDTH=20>&nbsp;</TD>";
echo "<TD VALIGN=top BGCOLOR=\"$THEME->cellcontent\" WIDTH=\"100%\">";
if (isediting($course->id)) {
$thisweek->summary .= "&nbsp;<A TITLE=\"$streditsummary\" ".
"HREF=\"editsection.php?id=$thisweek->id\"><IMG SRC=\"../pix/t/edit.gif\" ".
"BORDER=0 ALT=\"$streditsummary\"></A></P>";
}
// Now all the weekly modules
echo text_to_html($thisweek->summary);
print_section($course, $thisweek, $mods, $modnamesused);
if (isediting($course->id)) {
echo "<DIV ALIGN=right>";
popup_form("$CFG->wwwroot/course/mod.php?id=$course->id&section=$week&add=",
$modnames, "section$week", "", "$stradd...", "mods", $stractivities);
echo "</DIV>";
}
echo "</TD>";
echo "<TD NOWRAP BGCOLOR=\"$THEME->cellheading\" VALIGN=top ALIGN=CENTER WIDTH=10>";
echo "</TD>";
echo "</TR>";
echo "<TR><TD COLSPAN=3><IMG SRC=\"../pix/spacer.gif\" WIDTH=1 HEIGHT=1></TD></TR>";
}
/// Now all the weekly sections
$timenow = time();
$weekdate = $course->startdate; // this should be 0:00 Monday of that week
$week = 1;
$weekofseconds = 604800;
$course->enddate = $course->startdate + ($weekofseconds * $course->numsections);
$streditsummary = get_string("editsummary");
$stradd = get_string("add");
echo "<TABLE BORDER=0 CELLPADDING=8 CELLSPACING=0 WIDTH=100%>";
while ($weekdate < $course->enddate) {
$nextweekdate = $weekdate + ($weekofseconds);
@@ -99,8 +137,8 @@
$thisweek = (($weekdate <= $timenow) && ($timenow < $nextweekdate));
$weekday = date("j F", $weekdate);
$endweekday = date("j F", $weekdate+(6*24*3600));
$weekday = userdate($weekdate, " %d %B");
$endweekday = userdate($weekdate+518400, " %d %B");
if ($thisweek) {
$highlightcolor = $THEME->cellheading2;
@@ -131,12 +169,12 @@
echo text_to_html($thisweek->summary);
print_section($course->id, $thisweek, $mods, $modnamesused);
print_section($course, $thisweek, $mods, $modnamesused);
if (isediting($course->id)) {
echo "<DIV ALIGN=right>";
popup_form("$CFG->wwwroot/course/mod.php?id=$course->id&section=$week&add=",
$modnames, "section$week", "", "$stradd...");
$modnames, "section$week", "", "$stradd...", "mods", $stractivities);
echo "</DIV>";
}
@@ -159,30 +197,28 @@
}
echo "</TABLE>";
if ($news or $course->showrecent) {
echo "</TD><TD WIDTH=210>";
echo "</TD><TD WIDTH=210>";
// Print all the news items.
// Print all the news items.
if ($course->newsitems) {
if ($news = forum_get_course_forum($course->id, "news")) {
print_simple_box(get_string("latestnews"), $align="CENTER", $width="100%", $color="$THEME->cellheading");
print_simple_box_start("CENTER", "100%", "#FFFFFF", 3, 0);
echo "<FONT SIZE=1>";
if ($news) {
print_side_block_start(get_string("latestnews"), 210, "sideblocklatestnews");
echo "<FONT SIZE=\"-2\">";
forum_print_latest_discussions($news->id, $course->newsitems, "minimal", "DESC", false);
echo "</FONT>";
print_simple_box_end();
print_side_block_end();
}
// Print all the recent activity
if ($course->showrecent) {
print_side_block_start(get_string("recentactivity"), 210, "sideblockrecentactivity");
print_recent_activity($course);
print_side_block_end();
}
echo "<BR>";
}
// Print all the recent activity
print_simple_box(get_string("recentactivity"), $align="CENTER", $width="100%", $color="$THEME->cellheading");
print_simple_box_start("CENTER", "100%", "#FFFFFF", 3, 0);
print_recent_activity($course);
print_simple_box_end();
echo "<BR><IMG SRC=\"../pix/spacer.gif\" WIDTH=210 HEIGHT=1>";
print_spacer(1, 120, true);
}
echo "</TD></TR></TABLE>\n";
+5 -4
View File
@@ -10,7 +10,7 @@
<P>Moodle is an active and evolving work in progress.</P>
<P>I've been working on it, in some way or other, for several years. It started
in the 90's when I was webmaster at <a href="http://dougiamas.com/">Curtin University
in the 90's when I was webmaster at <a target=_top href="http://www.curtin.edu.au/">Curtin University
of Technology</a> and a system administrator of their WebCT installation. I
encountered many frustrations with the WebCT beast and developed an itch that
needed scratching - there had to be a better way (no, not Blackboard :-)</P>
@@ -24,8 +24,9 @@
career in Computer Science with newly constructed knowledge about the nature
of learning and collaboration.</P>
<P>Since then Moodle has progressed through several very different prototypes
to achieve something I'm ready to call version 1.0 and release upon an unsuspecting
world (August 20, 2002). I've been using it in several courses and find it an
until the release of version 1.0 upon a largely unsuspecting world on
August 20, 2002 and a steady series of improved releases since then.
<P>I've been using it in several courses and find it an
extremely usable and reliable tool for building high-quality online courses
- others are reporting the same. Given the context in which it's been designed,
it works particularly well for smaller institutions, or for smaller, more intimate
@@ -36,7 +37,7 @@
</P>
<P>&nbsp;</P>
<P ALIGN="CENTER"><FONT SIZE="1"><A HREF="index.html" TARGET="_top">Moodle Documentation</A></FONT></P>
<P ALIGN="CENTER"><FONT SIZE="1"><A HREF="." TARGET="_top">Moodle Documentation</A></FONT></P>
<P ALIGN="CENTER"><FONT SIZE="1">Version: $Id$</FONT></P>
</BODY>
+2
View File
@@ -11,7 +11,9 @@
<LI><A TARGET="main" HREF="background.html">Background</A>
<LI><A TARGET="main" HREF="features.html">Features</A>
<LI><A TARGET="main" HREF="release.html">Release Notes</A>
<LI><A TARGET="main" HREF="install.html">Installation</A>
<LI><A TARGET="main" HREF="upgrade.html">Upgrading</A>
<LI><A TARGET="main" HREF="teacher.html">Teacher Manual</A>
<LI><A TARGET="main" HREF="developer.html">Developer Manual</A>
<LI><A TARGET="main" HREF="future.html">Future</A>
+21
View File
@@ -0,0 +1,21 @@
<?PHP // $Id$
require("../config.php");
print_header();
?>
<FONT SIZE=2 FACE="san-serif">
<LI><A TARGET="main" HREF="intro.html">Introduction</A>
<LI><A TARGET="main" HREF="background.html">Background</A>
<LI><A TARGET="main" HREF="features.html">Features</A>
<LI><A TARGET="main" HREF="release.html">Release Notes</A>
<LI><A TARGET="main" HREF="install.html">Installation</A>
<LI><A TARGET="main" HREF="upgrade.html">Upgrading</A>
<LI><A TARGET="main" HREF="teacher.html">Teacher Manual</A>
<LI><A TARGET="main" HREF="developer.html">Developer Manual</A>
<LI><A TARGET="main" HREF="future.html">Future</A>
<LI><A TARGET="main" HREF="credits.html">Credits</A>
<LI><A TARGET="main" HREF="licence.html">License</A>
</FONT>
+105 -38
View File
@@ -8,27 +8,76 @@
<H2>Credits</H2>
<P><B>Moodle </B>itself is Copyright &copy; 2001-2002, <A HREF="http://dougiamas.com/">
<P><B>Moodle </B>itself is Copyright &copy; 2001-2002, <A TARGET=_top HREF="http://dougiamas.com/">
Martin Dougiamas</A>. &nbsp;It is distributed under the <A HREF="licence.html">
GNU Public License</A>.</P>
<H3>Other contributors</H3>
<H3><BR>Special thanks</H3>
<UL>
<LI><B>Dr Peter Taylor</B>, at Curtin University of Technology, for working
with the prototype and making many useful suggestions</LI>
<LI><B><A TARGET=_top HREF="http://pctaylor.com">Dr Peter C. Taylor</A></B>, at Curtin University of Technology in Perth, Australia, for working
with the prototypes and making many useful suggestions along the way
<LI><B>Art Lader</B>, at Aiken High School, SC, USA for many good deeds.
</UL>
<BR>
<H3><BR>Translations</H3>
<BLOCKQUOTE>
<P>Many thanks to these people - each translation takes many hours of work, as there are nearly
900 phrases to translate (plus all the help files!).
These are listed in the order they joined the project:
<UL>
<LI><B>fr - French</B>, by Sébastien Namèche, seb@gaia.anet.fr, <A HREF="http://gaia.anet.fr/">http://gaia.anet.fr/</A>
<LI><B>fi - Finnish</B>, by Petri Asikainen (paca@sci.fi), Jaana Tolvanen (jaanat@cedunet.com)
<LI><B>it - Italian</B>, by Davide Suraci, icarused@tiscalinet.it
<LI><B>pt_br - Portuguese (Brazil)</B>, by Fabricio Valadares, webdesigner@unincor.br
<LI><B>de - German</B>, by Holger Schadeck, Holger.Schadeck@webdesign-forum.de
<LI><B>es_mx - Spanish (Mexico)</B>, by Claudio Tavares, <A HREF="http://enlaceacademico.com">enlaceacademico.com</A>
<LI><B>es_es - Spanish </B>, by Antonio J. Navarro Vergara, anavarro@sextaisla.com, <A HREF="http://www.sextaisla.com">www.sextaisla.com</A>
<LI><B>ca - Catalan</B>, by Carles Bellver with the help of Mercè Renau,
Clara Andrés and Jordi Adell, cent@uji.es, <A HREF="http://cent.uji.es">Centre d'Educació i Noves Tecnologies</A>
<LI><B>no - Norwegian</B>, by Jøran Sørbø, joran.sorbo@teleweb.no
<LI><B>id - Indonesian</B>, by Arfan Hidayat, ivanh@telkom.net, <A HREF="http://www.kursusmaya.com">http://www.kursusmaya.com</A>
<LI><B>ja - Japanese</B>, by Mitsuhiro Yoshida, mits@mitstek.com, <A HREF="http://mitstek.com">http://mitstek.com</A>
</UL>
</BLOCKQUOTE>
<H3><BR>Other contributors</H3>
<BLOCKQUOTE>
<P>Thanks to all of you contributing ideas and code, including:
<UL>
<LI>Petri Asikainen,
<LI>Matt Hope,
<LI>James Miller,
<LI>Tom Murdock,
<LI>Sebastien Nameche,
<LI>Dustin Rue,
<LI>Giovanni Tummarello,
</UL>
... and also:</P>
<UL>
<LI>anyone else who has made donations via the <A TARGET=_top HREF="http://moodle.com/donations">Donations page</A>,
<LI>everyone else who contributes to the <A TARGET=_top HREF="http://bugs.moodle.com">bug tracker</A>, and
<LI>everyone enrolled in the "<A TARGET=_top HREF="http://moodle.com/course/">Using Moodle</A>" course at moodle.com</A>
<LI>and anyone else I've inadvertently forgotten!
</UL>
</BLOCKQUOTE>
<P></P>
<H3>Moodle libraries</H3>
<H3><BR>Moodle libraries</H3>
<BLOCKQUOTE>
<P>Some of Moodle's libraries were written by other people, and are being
redistributed as part of Moodle under the LGPL. &nbsp;Copyright information
from this software is included below:</P>
redistributed as part of Moodle under the LGPL. My thanks go out to the
authors of all these excellent products - without them Moodle would be missing
important functionality. Copyright information for each package is included below:</P>
<P><B>ADOdb &nbsp; </B>- &nbsp;lib/adodb<BR>
</P>
@@ -50,11 +99,23 @@ Interbase, Foxpro, Access, ADO, Sybase, DB2 and ODBC.</P>
<P>Class to draw line, point, bar, and area graphs, including numeric
x-axis and double y-axis.</P>
<P> Version: 1.6.3<BR>
<P> Version: 1.6.3 (with modifications)<BR>
Copyright &copy;&nbsp;2000&nbsp; Herman Veluwenkamp,&nbsp;hermanV@mindless.com<BR>
License: LGPL<BR>
</P>
</BLOCKQUOTE>
<P><B>IP-Atlas</B>&nbsp; - &nbsp; lib/ipatlas</P>
<BLOCKQUOTE>PHP scripts to show the location of an IP address on a map.<BR>
<BR>
Version: 1.0 (with modifications)<BR>
Copyright &copy; 2002 &nbsp; Ivan Kozik<BR>
License: GNU GPL<BR>
URL: <A HREF="http://www.xpenguin.com/ip-atlas.php" TARGET="newpage">http://www.xpenguin.com/ip-atlas.php</A><BR>
</BLOCKQUOTE>
<P><B>PHP mailer</B> &nbsp; - &nbsp;lib/class.phpmailer.php<BR>
</P>
@@ -62,12 +123,40 @@ Interbase, Foxpro, Access, ADO, Sybase, DB2 and ODBC.</P>
<BLOCKQUOTE>Class for sending email using either sendmail, PHP mail(),
or SMTP.&nbsp; Methods are based upon the standard AspEmail(tm) classes.<BR>
<BR>
Version 1.25, Created 07/02/2001<BR>
Version 1.60, Created 03/30/2002<BR>
Copyright &copy; 2001 Brent R. Matzelle &lt;bmatzelle@yahoo.com&gt;<BR>
License: LGPL<BR>
URL: &nbsp; <A HREF="http://phpmailer.sourceforge.net" TARGET="newpage">http://phpmailer.sourceforge.net</A><BR>
<BR>
</BLOCKQUOTE>
<P><B>PHP Simple Excel File Generator</B>&nbsp; - &nbsp; lib/psxlsgen.php</P>
<BLOCKQUOTE>Class to generate very simple MS Excel files (xls)
via PHP.<BR>
<BR>
Version: 0.3b<BR>
Copyright &copy; 2001 &nbsp;Erol Ozcan &lt;eozcan@superonline.com&gt;<BR>
License: GNU LGPL<BR>
URL: <A HREF="http://psxlsgen.sourceforge.net" TARGET="newpage">http://psxlsgen.sourceforge.net</A><BR>
</BLOCKQUOTE>
<P><B>Richtext Editor</B>&nbsp; - &nbsp; lib/rte</P>
<BLOCKQUOTE>HTML text editor for embedding in web pages.<BR>
<BR>
Version: 0.30 beta 1 (plus modifications)<BR>
Copyright &copy; 2001 Ramesys (Contracting Services) Limited &lt;Austin.France@Ramesys.com&gt;
License: GNU LGPL<BR>
URL: <A HREF="http://richtext.sourceforge.net" TARGET="newpage">http://richtext.sourceforge.net</A><BR>
</BLOCKQUOTE>
<P><B>SMTP class &nbsp; </B>- &nbsp;lib/class.smtp.php<BR>
</P>
@@ -81,33 +170,11 @@ or SMTP.&nbsp; Methods are based upon the standard AspEmail(tm) classes.<BR>
<BR>
</BLOCKQUOTE>
<P><B>PHP Simple Excel File Generator</B>&nbsp; - &nbsp; lib/psxlsgen.php</P>
<BLOCKQUOTE>Class to generate very simple MS Excel files (xls)
via PHP.<BR>
<BR>
Version: 0.3b<BR>
Copyright &copy; 2001 &nbsp;Erol Ozcan &lt;eozcan@superonline.com&gt;<BR>
License: GNU LGPL<BR>
URL: <A HREF="http://psxlsgen.sourceforge.net">http://psxlsgen.sourceforge.net</A><BR>
</BLOCKQUOTE>
<P><B>IP-Atlas</B>&nbsp; - &nbsp; lib/ipatlas</P>
<BLOCKQUOTE>PHP scripts to show the location of an IP address on a map.<BR>
<BR>
Version: 1.0<BR>
Copyright &copy; 2002 &nbsp; Ivan Kozik<BR>
License: GNU GPL<BR>
URL: <A HREF="http://www.xpenguin.com/ip-atlas.php">http://www.xpenguin.com/ip-atlas.php</A><BR>
</BLOCKQUOTE>
</BLOCKQUOTE>
<BLOCKQUOTE><BR>
</BLOCKQUOTE>
<P ALIGN="CENTER"><FONT SIZE="1"><A HREF="index.html" TARGET="_top">Moodle Documentation</A></FONT></P>
<P ALIGN="CENTER"><FONT SIZE="1"><A HREF="." TARGET="_top">Moodle Documentation</A></FONT></P>
<P ALIGN="CENTER"><FONT SIZE="1">Version: $Id$</FONT></P>
Executable
+87
View File
@@ -0,0 +1,87 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<HTML>
<HEAD>
<TITLE>Moodle Docs: How to use CVS</TITLE>
<LINK REL="stylesheet" HREF="../theme/standard/styles.css" TYPE="TEXT/CSS">
</HEAD>
<BODY BGCOLOR="#ffffff">
<H2>How to use CVS</H2>
<BLOCKQUOTE>
<P>CVS is the Concurrent Versioning System. It's a commonly used way
of storing source code because it keeps versions of all files so
that nothing is ever lost, and usage by different people is tracked.</P>
<P>To use Moodle's CVS archive (as a developer) from a Unix machine, you first
need to have an account on <a href="http://www.sf.net/">Sourceforge</a>. For
the example, let's assume your username is <strong>myusername</strong> and your
password is <strong>mypassword</strong>. Secondly, you need to contact me (<A
HREF="http://dougiamas.com/">Martin Dougiamas</A>) to get write access
to particular directories.</P>
<P>With that done, you should have all the permissions you need, so you just need
to set up your machine and download the current sources so you can start working
on them.</P>
<P>Sourceforge CVS uses ssh as a transport layer for security, so you will have
to set this CVS_RSH environment variable in your Unix shell:</P>
<blockquote>
<pre><strong>setenv CVS_RSH ssh</strong> (for csh, tcsh etc)</pre>
<pre><strong>export CVS_RSH=ssh</strong> (for sh, bash etc)</pre>
</blockquote>
<p>It's best to put this in your .bashrc or .cshrc so you don't have to type it
all the time. Then, check out Moodle using this (all one line): </p>
<blockquote>
<pre><strong>cvs -z3 -d:ext:myusername@cvs.moodle.sourceforge.net:/cvsroot/moodle co moodle</strong></pre>
</blockquote>
<p>Don't try to do run this first CVS command into an existing moodle directory
- start fresh with a new directory.</p>
<p>Note that you will be prompted for <strong>mypassword</strong> with each CVS
command. To avoid this, follow the <a href="http://sourceforge.net/account/editsshkeys.php">Sourceforge
directions about using authorized keys</a>.</p>
<p>Now, you should have a new 'moodle' directory. You can rename it and move it
around if you like. Go into it: </p>
<blockquote>
<pre><strong>cd moodle </strong></pre>
</blockquote>
<p>All the latest Moodle files should be in there. You can now change files in
your copy. To compare your files against the main CVS copy on the server use
cvs diff, eg: </p>
<blockquote>
<pre><strong>cvs diff -c config-dist.php
cvs diff -c lang</strong></pre>
</blockquote>
<p>To fetch the latest updates from the server use: </p>
<blockquote>
<pre><strong>cvs update -dP</strong> </pre>
</blockquote>
<p>To copy your new files back to the server you would do: </p>
<blockquote>
<pre><strong>cd lang/ca
cvs commit</strong> </pre>
</blockquote>
<p>You will be prompted to add some comments (depends on your default text editor)
... add a comment and close the editor ... the files will be sent to Sourceforge
and stored. Done! </p>
<p>To save more time you can put default arguments into a file called .cvsrc in
your home directory. For example, mine contains: </p>
<blockquote>
<pre><strong>diff -c
update -dP</strong> </pre>
</blockquote>
<p>Try 'cvs help' for more details ... </p>
<P>&nbsp;</P>
</BLOCKQUOTE>
<P ALIGN="CENTER"><FONT SIZE="1"><A HREF="." TARGET="_top">Moodle Documentation</A></FONT></P>
<P ALIGN="CENTER"><FONT SIZE="1">Version: $Id: features.html,v 1.2 2001/12/09
10:34:19 martin Exp $</FONT></P>
</BODY>
</HTML>
+11 -9
View File
@@ -71,11 +71,12 @@
One thing Moodle does is keep all files for one course within a single, normal
directory on the server. This would allow a system administrator to provide
seamless forms of file-level access for each teacher, such as Appletalk, SMB,
NFS, FTP, WebDAV and so on. Otherwise, there is work yet to do. Features planned
for Moodle in future versions include: flexible connection to existing databases
of user details and grades; import and export of Moodle data using XML-based
formats; and increased use of style sheets for interface formatting (so that
it can be integrated visually into other web sites).</li>
NFS, FTP, WebDAV and so on. The authentication modules allow Moodle to use
LDAP, IMAP, POP3, NNTP and other databases as sources for user information.
Otherwise, there is work yet to do. Features planned
for Moodle in future versions include: import and export of Moodle data using XML-based
formats (including IMS and SCORM); and increased use of style sheets for
interface formatting (so that it can be integrated visually into other web sites).</li>
</ol>
<p>&nbsp;</p>
<H3><a name="contribute" id="contribute"></a>2. How you can contribute</H3>
@@ -84,7 +85,7 @@
<P><strong><a name="activities" id="activities"></a>Learning Activities</strong></P>
<blockquote>
<p>These are by far the most important modules, and reside in the 'mod' directory.
There are six default modules: assignment, choice, forum, journal, reading,
There are seven default modules: assignment, choice, forum, journal, quiz, resource,
and survey. Each module is in a separate subdirectory and consists of the
following mandatory elements (plus extra scripts unique to each module):</p>
<ul>
@@ -140,8 +141,9 @@
<li>choice.php - strings for choice module</li>
<li>forum.php - strings for forum module</li>
<li>journal.php - strings for journal module </li>
<li>reading.php - strings for reading module</li>
<li>survey.php - strings for reading module</li>
<li>quiz.php - strings for quiz module</li>
<li>resource.php - strings for resource module</li>
<li>survey.php - strings for survey module</li>
<li>.... plus other modules if any.<br>
<br>
A string is called from these files using the <strong><em>get_string()</em></strong><em>
@@ -228,7 +230,7 @@
<blockquote>
<p>&nbsp;</p>
</blockquote>
<P ALIGN="CENTER"><FONT SIZE="1"><A HREF="index.html" TARGET="_top">Moodle Documentation</A></FONT></P>
<P ALIGN="CENTER"><FONT SIZE="1"><A HREF="." TARGET="_top">Moodle Documentation</A></FONT></P>
<P ALIGN="CENTER"><FONT SIZE="1">Version: $Id: developer.html,v 1.2 2001/12/09
10:34:19 martin Exp $</FONT></P>
+140 -15
View File
@@ -7,26 +7,151 @@
<BODY BGCOLOR="#ffffff">
<H2>Features</H2>
Here is a big list of some of the features in Moodle 1.0:
<UL><LI>Supports a social constructionist pedagogy (collaboration, activities, critical reflection, etc)</LI><LI>Suitable for 100% online classes as well as supplementing face-to-face learning<LI>Simple, lightweight, browser-compatible interface</LI><LI>Plug-in "themes" allow you to customise the colours, fonts, layout etc</LI><LI>Easy to install on most platforms</LI><LI>Easy administration - students can create their own accounts. Email addresses are verified.</LI><LI>One account works for the whole server</LI><LI>Security - teachers can add an "enrolment key" to their courses to keep out non-students. They can give out this key face-to-face or via personal email etc</LI><LI>Students are encouraged to build an online profile including photos, description etc</LI><LI>Every user can specify their own timezone, and every date in Moodle is translated to that timezone (eg posting dates, assignment due dates etc)</LI><LI>Choice of course formats such as by week, by topic or a discussion-focussed social format</LI><LI>Flexible array of course modules - Forums, Journals, Readings, Choices, Surveys, Assignments.</LI><LI>New modules can be written and plugged in to existing Moodle installations</LI><LI>The code is clearly-written PHP under a GPL license - easy to modify and localise</LI><LI>Full database abstraction supports all major brands of database (except for initial table definition)</LI><LI>Ready for internationalisation - supports plug-in languages and locale-based date formats etc</LI><LI>Mail integration - copies of forum posts, teacher feedback etc can be mailed in HTML or plain text.</LI><LI>Recent changes to the course since the last login are displayed on the course home page</LI><LI>Full user logging and tracking - activity reports for each student are available with graphs and details about each module (last access, number of times read) as well as a detailed "story" of each students involvement including postings, journal entries etc on one page.</LI>
<p>Moodle is an active and evolving product. This page lists some of the many
features it contains:</p>
<p><strong>Overall design</strong></p>
<UL>
<LI>Promotes a social constructionist pedagogy (collaboration, activities, critical
reflection, etc)</LI>
<LI>Suitable for 100% online classes as well as supplementing face-to-face learning
<LI>Simple, lightweight, efficient, compatible, low-tech browser interface</LI>
<LI>Easy to install on almost any platform that supports PHP. Requires only
one database.</LI>
<LI>Full database abstraction supports all major brands of database (except
for initial table definition)</LI>
<LI>Course listing shows descriptions for every course on the server, including
accessibility to guests.</LI>
<LI>Emphasis on strong security throughout. Forms are all checked, data validated,
cookies encrypted etc</LI>
</UL>
<B>Forum Module</B>
<UL><LI>Different types of forums are available, such as teacher-only, course news, open-to-all, and one-thread-per-user.</LI><LI>All postings have the authors photo attached.</LI><LI>Discussions can be viewed nested, flat or threaded, oldest or newest first.</LI><LI>Individual forums can be subscribed to by each person so that copies are forwarded via email, or the teacher can force subscription for all</LI>
<p><strong>Site management</strong></p>
<UL>
<LI>Site is managed by an admin user, defined during setup</LI>
<LI>Plug-in "themes" allow the admin to customise the site colours, fonts, layout
etc to suit local needs</LI>
<LI>Plug-in activity modules can be added to existing Moodle installations</LI>
<LI>Plug-in language packs allow full localisation to any language. These can
be edited using a built-in web-based editor.</LI>
<LI>The code is clearly-written PHP under a GPL license - easy to modify to
suit your needs</LI>
</UL>
<B>Survey Module</B>
<p><strong>User management</strong></p>
<UL>
<LI>Goals are to reduce admin involvement to a minimum, while retaining high
security</LI>
<LI>Supports a range of authentication mechanisms through plug-in authentication
modules, allowing easy integration with existing systems.</LI>
<LI>Standard email method: students can create their own login accounts. Email
addresses are verified by confirmation.</LI>
<LI>LDAP method: account logins can be checked against an LDAP server. Admin
can specify which fields to use.</LI>
<LI>IMAP, POP3, NNTP: account logins are checked against a mail or news server.
SSL, certificates and TLS are supported.</LI>
<LI>External database: any database containing at least two fields can be used
as an external authentication source.</LI>
<LI>Each person requires only one account for the whole server - each account
can have different access</LI>
<LI>An admin account controls the creation of courses and creates teachers by
assigning users to courses</LI>
<LI>Security - teachers can add an "enrolment key" to their courses to keep
out non-students. They can give out this key face-to-face or via personal
email etc</LI>
<LI>Teachers can unenrol students manually if desired, otherwise they are automatically
unenrolled after a certain period of inactivity (set by the admin)</LI>
<LI>Students are encouraged to build an online profile including photos, description.
Email addresses can be protected from display if required.</LI>
<LI>Every user can specify their own timezone, and every date in Moodle is translated
to that timezone (eg posting dates, assignment due dates etc)</LI>
<LI>Every user can choose the language used for the Moodle interface (English,
French, German, Spanish, Portuguese etc)</LI>
</UL>
<p><strong>Course management</strong></p>
<UL>
<LI>Teacher has full control over all settings for a course</LI>
<LI>Choice of course formats such as by week, by topic or a discussion-focussed
social format</LI>
<LI>Flexible array of course activities - Forums, Journals, Quizzes, Resources,
Choices, Surveys, Assignments.</LI>
<LI>Recent changes to the course since the last login can be displayed on the
course home page - helps give sense of community</LI>
<LI>Most text entry areas (resources, forum postings, journal entries etc) can
be edited using an embedded WYSIWYG HTML editor</LI>
<LI>All grades for Forums, Journals, Quizzes and Assignments can be viewed on
one page (and downloaded as a spreadsheet file)</LI>
<LI>Full user logging and tracking - activity reports for each student are available
with graphs and details about each module (last access, number of times read)
as well as a detailed "story" of each students involvement including postings,
journal entries etc on one page.</LI>
<LI>Mail integration - copies of forum posts, teacher feedback etc can be mailed
in HTML or plain text.</LI>
</UL>
<B>Assignment Module</B>
<UL>
<LI>Assignments can be specified with a due date and a maximum grade.</LI>
<LI>Students can upload their assignments (any file format) to the server -
they are date-stamped.</LI>
<LI>Late assignments are allowed, but the amount of lateness is shown clearly
to the teacher</LI>
<LI>For each particular assignment, the whole class can be assessed (grade and
comment) on one page in one form.</LI>
<LI>Teacher feedback is appended to the assignment page for each student, and
notification is mailed out.</LI>
<LI>The teacher can choose to allow resubmission of assignments after grading
(for regrading)</LI>
</UL>
<P><B>Choice Module</B> </P>
<UL>
<LI>Like a poll. Can either be used to vote on something, or to get feedback
from every student (eg research consent)</LI>
<LI>Teacher sees intuitive table view of who chose what</LI>
</UL>
<P><B>Forum Module</B> </P>
<UL>
<LI>Different types of forums are available, such as teacher-only, course news,
open-to-all, and one-thread-per-user.</LI>
<LI>All postings have the authors photo attached.</LI>
<LI>Discussions can be viewed nested, flat or threaded, oldest or newest first.</LI>
<LI>Individual forums can be subscribed to by each person so that copies are
forwarded via email, or the teacher can force subscription for all</LI>
<LI>The teacher can choose not to allow replies (eg for an announcements-only
forum)</LI>
</UL>
<B>Journal Module</B>
<UL>
<LI>Journals are private between student and teacher.</LI>
<LI>Each journal entry can be directed by an open question.</LI>
<LI>For each particular journal entry, the whole class can be assessed on one
page in one form</LI>
<LI>Teacher feedback is appended to the journal entry page, and notification
is mailed out.</LI>
</UL>
<P><B>Quiz Module</B> </P>
<UL>
<LI>Teachers can define a database of questions for re-use in different quizzes</LI>
<LI>Quizzes are automatically graded, and can be re-graded if questions are
modified </LI>
<LI>Quizzes can have a limited time window outside of which they are not available</LI>
<LI>At the teacher's option, quizzes can be attempted multiple times, and can
show feedback and/or correct answers</LI>
<LI>Questions allow HTML and images</LI>
<LI>Multiple-choice questions supporting single or multiple answers</LI>
<LI>Short Answer questions (words or phrases)</LI>
<LI>True-False questions </LI>
</UL>
<P><B>Resource Module</B> </P>
<UL>
<LI>Supports display of any electronic content</LI>
<LI>Files can be uploaded and managed on the server, or created on the fly using
web forms (text or HTML)</LI>
<LI>External content on the web can be linked to or seamlessly included within
the course interface.</LI>
</UL>
<B>Survey Module</B>
<UL><LI>Built-in surveys (COLLES, ATTLS) have been proven as instruments for analysing online classes</LI><LI>Online survey reports always available, including many graphs. Data is downloadable as an Excel spreadsheet or CSV text file.</LI><LI>Survey interface prevents partly-finished surveys.</LI><LI>Feedback is provided to the student of their results compared to the class averages</UL>
<B>Readings Module</B>
<UL><LI>Supports display of any electronic content</LI><LI>Files can be uploaded and managed on the server, or created on the fly using web forms (text or HTML)</LI><LI>External content on the web can be linked to or seamlessly included within the course interface.</LI></UL>
<B>Choice Module</B>
<UL><LI>Like a poll. Can either be used to vote on something, or to get feedback from every student (eg research consent)</LI></UL>
<B>Journal Module</B>
<UL><LI>Journals are private between student and teacher.</LI><LI>Each journal entry can be directed by an open question.</LI><LI>For each particular journal entry, the whole class can be assessed on one page in one form.</LI><LI>Teacher feedback is appended to the journal entry page, and notification is mailed out.</LI></UL>
<B>Assignment Module</B>
<UL><LI>Assignments can be specified with a due date and a maximum grade.</LI><LI>Students can upload their assignments (any file format) to the server - they are date-stamped.</LI><LI>Late assignments are allowed, but the amount of lateness is shown clearly to the teacher</LI><LI>For each particular assignment, the whole class can be assessed (grade and comment) on one page in one form.</LI><LI>Teacher feedback is appended to the assignment page for each student, and notification is mailed out.</LI></UL>
<P>&nbsp;</P>
<P ALIGN="CENTER"><FONT SIZE="1"><A HREF="index.html" TARGET="_top">Moodle Documentation</A></FONT></P>
<P ALIGN="CENTER"><FONT SIZE="1"><A HREF="." TARGET="_top">Moodle Documentation</A></FONT></P>
<P ALIGN="CENTER"><FONT SIZE="1">Version: $Id: features.html,v 1.2 2001/12/09
10:34:19 martin Exp $</FONT></P>
+21 -22
View File
@@ -14,33 +14,32 @@
<P>As Moodle gains in maturity, I hope its directions are influenced by the community
of developers and users. A dynamic database of proposed features and their status
can be found at <A TARGET=_top HREF="http://bugs.moodle.org/">bugs.moodle.org</A>.
Your <a href="developer.html">contributions</a> in the form of ideas, code,
Your <A href="developer.html">contributions</a> in the form of ideas, code,
feedback and promotion are all very welcome.
<P>Now that 1.0.1 has been released, most of my efforts will concentrate on the
macro level (supporting larger classes and integrating into larger institutions)
and the micro level (improving support for decisions and processes, for both
teachers and learners).
<P>Until about April 2003, my own involvement will slow down while I finish my PhD thesis.
During this time there will still be releases, but they will only contain minor
new features and bug fixes. I will also be including modules and other code contributed
by others.
<P>The next 6 months or so I will have to slow down my own development a little
(because I have a PhD thesis to finish). During this time there'll be a number
of small upgrades 1.0.2, 1.0.3 etc that I expect will contain minor new features
and polishing. I'll also be working with people adding new plugins (support for
more databases, new modules and new themes).
<P>After this time, by around June/July 2003, I am expecting a major release called Moodle 2.0
that will include major new features such as:
<UL>
<LI>Stronger pedagogical support for both teachers and students
<LI>Support for groups and group work
<LI>Rewritten display incorporating XML, XSL and CSS for full flexibility
and compatibility with all modern web standards.
<LI>Basic support for IMS and SCORM
<LI>A variety of new modules (chat, tracker etc)
<LI>Whatever else seems most important at the time :-)
</UL>
<P>Sometime in the first half of 2003 you can expect a major release (1.1, maybe 1.5) that has
new features like:
<UL>
<LI>Full user account management (eg connection to external databases, import/export etc)
<LI>Full grade management
<LI>Ability to define groups and group work
<LI>Automatic linking in texts to uploaded readings (like Wiki)
<LI>Online support for teachers to design and maintain classes
<LI>Online support for students in collaboration processes
</UL>
<P>About this time I will also be experimenting with ways of making
Moodle development more sustainable for the long term. This may
include offering services for payment - although the software itself
will always remain Free.
<P ALIGN="CENTER">&nbsp;</P>
<P ALIGN="CENTER"><FONT SIZE="1"><A HREF="index.html" TARGET="_top">Moodle Documentation</A></FONT></P>
<P ALIGN="CENTER"><FONT SIZE="1"><A HREF="." TARGET="_top">Moodle Documentation</A></FONT></P>
<P ALIGN="CENTER"><FONT SIZE="1">Version: $Id$</FONT></P>
</BODY>
+25
View File
@@ -0,0 +1,25 @@
<?PHP // $Id$
require("../config.php");
optional_variable($file, "intro.html"); // file in this directory to view
$file = clean_filename($file);
if (!file_exists($file)) {
error("404 - File not found");
}
?>
<HEAD>
<TITLE>Moodle Documentation</TITLE>
</HEAD>
<FRAMESET ROWS="70,*">
<FRAME NAME="top" SRC="top.php">
<FRAMESET COLS="200,*">
<FRAME NAME="contents" SRC="contents.php">
<FRAME NAME="main" SRC="<?PHP echo "$file"; ?>">
</FRAMESET>
</FRAMESET>
+101 -32
View File
@@ -5,7 +5,11 @@
<BODY BGCOLOR="#FFFFFF">
<H2>Installing Moodle</H2>
<P>This guide explains how to install Moodle for the first time.</P>
<P>This guide explains how to install Moodle for the first time. It goes into some detail
about some of the steps, in order to cover the wide variety of small differences between
web server setups, so this document may look long and complicated. Don't be put off by this
- I usually set Moodle up in a few minutes!</P>
<P>Take your time and work through this document carefully - it will save you time later on.</P>
<P>Sections in this document:</P>
<OL>
<LI><A HREF="#requirements">Requirements</A></LI>
@@ -26,14 +30,19 @@
<p>All you should need are:</p>
<ul>
<li>a working installation of <A HREF="http://www.php.net/">PHP</A> (version
4.1.0 or better), including the <A HREF="http://www.boutell.com/gd/">GD</A>
library for manipulating images.</li>
4.1.0 or later), with the following features enabled (most PHP installations
these days will have all of these):
<ul>
<LI>JPEG and/or PNG image editing support via the <A HREF="http://www.boutell.com/gd/">GD library</A></li>
<LI>Sessions support
<LI>File uploading
</UL>
<li>a working database server (<A HREF="http://www.mysql.com/">MySQL</A> for
now, but soon it will support PostgreSQL, MSSQL, Oracle, Interbase, Foxpro,
Access, ADO, Sybase, DB2 or ODBC).</li>
</ul>
<p>On a Windows platform, the quickest way to satisfy these requirements is
to download <A HREF="http://www.phpgeek.com/">PHPTriad</A>, <A HREF="http://www.foxserv.net/">FoxServ</A>,
to download <A HREF="http://www.foxserv.net/">FoxServ</A>,
or <A HREF="http://www.easyphp.org/">EasyPHP</A> which will install Apache,
PHP, and MySQL for you. Make sure you enable the GD module so Moodle can process
images - you may have to edit php.ini and remove the comment (;) from this
@@ -65,6 +74,7 @@
index.php - the front page of the site</p>
<ul>
<li>admin/ - code to administrate the whole server </li>
<li>auth/ - plugin modules to authenticate users </li>
<li>course/ - code to display and manage courses </li>
<li>doc/ - help documentation for Moodle (eg this page)</li>
<li>files/ - code to display and manage uploaded files</li>
@@ -83,19 +93,30 @@
<blockquote>
<p>Moodle will also need some space on your hard disk to store uploaded files,
such as course documents and user pictures.</p>
<p>Create a directory for this purpose somewhere <B>away</B> from the web server
documents directory (we don't want these files to be directly accessible from
the web), and ensure that the web server software has permission to write
<p>Create a directory for this purpose somewhere. For security, it's best that
this directory is NOT accessible via the web. The easiest way to do this
is to simply locate it OUTSIDE the web directory, otherwise protect it
by creating a file in the data directory called .htaccess, containing this line:
<blockquote>
<PRE>deny from all</PRE>
</blockquote>
<p>To make sure that Moodle can save uploaded files in this directory, check that
the web server software (eg Apache) has permission to write
to this directory. On Unix machines, this means setting the owner of the directory
to be something like &quot;nobody&quot; or &quot;apache&quot;.</p>
</blockquote>
<P>&nbsp;</P>
<H3><A NAME="database"></A>5. Create a database</H3>
<blockquote>
<p>You need to create an empty database (eg "moodle") in your database system
<p>You need to create an empty database (eg "moodle") in your database system
along with a special user (eg "moodleuser") that has access to that database
(and that database only. For example, don't use the "root" user for the moodle
database in a production system - it's a security hazard). </p>
(and that database only). You could use the "root" user if you wanted to, but
this is not recommended for a production system: if hackers manage to discover
the password then your whole database system would be at risk, rather than
just one database.
</p>
<p>eg for MySQL: </p>
<PRE>
# mysql -u root -p
@@ -107,6 +128,11 @@
</PRE>
<p>(For MySQL I highly recommend the use of <a href="http://phpmyadmin.sourceforge.net/">phpMyAdmin</a>
to manage your databases).</p>
<p>Note that Moodle currently does not yet support table name prefixes, and works best with a whole
database to itself. If you do want to install Moodle in a database that already contains
tables, and are SURE that Moodle tables will not conflict with any tables
that you already have installed, then you can call this script in your moodle
installation: admin/forcetables.php</p>
</blockquote>
<P>&nbsp;</P>
<H3><A NAME="webserver" id="webserver"></A>6. Check your web server settings</H3>
@@ -120,13 +146,44 @@
</blockquote>
<p>Just make sure index.php is in the list (and preferably towards the start
of the list, for efficiency).</p>
<p>Secondly, check your PHP configuration file (usually called php.ini) and
make sure uploading has been turned on:</p>
<p>Secondly, Moodle requires a number of PHP settings to be active for it to
work. <B>On most servers these will already be the default settings.</B>
However, some PHP servers (and some of the more recent PHP versions) may
have things set differently. These are defined in PHP's configuration
file (usually called php.ini):</p>
<blockquote>
<pre>file_uploads = On</pre>
<pre>file_uploads = 1
magic_quotes_gpc = 1
short_open_tag = 1
session.auto_start = 0
</pre>
</blockquote>
<p>Most distributions of PHP have this turned on by default, but you may want
to check it anyway. </p>
<p>If you don't have access to httpd.conf or php.ini on your server, or you
have Moodle on a server with other applications that require different
settings, then you can OVERRIDE all of the default settings.
<p>To do this, you need to create a file called <B>.htaccess</B> in Moodle's
main directory that contains definitions for these settings.
This only works on Apache servers and only when Overrides have been allowed.
<BLOCKQUOTE><PRE>
DirectoryIndex index.php index.html index.htm
php_value magic_quotes_gpc 1
php_value file_uploads 1
php_value short_open_tag 1
php_value session.auto_start 0</BLOCKQUOTE></PRE>
<P>You can also do things like define the maximum size for uploaded files:
<BLOCKQUOTE><PRE>
php_value upload_max_filesize 2M
php_value post_max_size 2M
</BLOCKQUOTE></PRE>
<p>The easiest thing to do is just copy the sample file from lib/htaccess
and edit it to suit your needs. It contains further instructions. For
example, in a Unix shell:
<blockquote>
<pre>cp lib/htaccess .htaccess</pre>
</blockquote>
</blockquote>
<p>&nbsp;</p>
<H3><A NAME="config"></A>7. Edit config.php</H3>
@@ -137,7 +194,7 @@
do this so that your config.php won't be overwritten in case you upgrade Moodle
later on. </p>
<p>Edit config.php to specify the database details that you just defined, as
well as the site address, file system directory, data directory and so on.
well as the site address, file system directory and data directory.
The config file has detailed directions.</p>
<p>For the rest of this installation document we will assume your site is at:
<u>http://example.com/moodle</u></p>
@@ -145,15 +202,15 @@
<P>&nbsp;</P>
<H3><A NAME="admin"></A>8. Go to the admin page</H3>
<blockquote>
<p>The admin page should now be working at: http://example.com/moodle/admin.
<p>The admin page should now be working at: <u>http://example.com/moodle/admin</u>.
If you try and access the front page of your site you'll be taken there automatically
anyway. The first time you access this admin page, you will be presented with
a GPL agreement which you need to agree with to continue with the setup.</p>
a GPL agreement with which you need to agree before you can continue with the setup.</p>
<P>(Moodle will also try to set some cookies in your browser. If you have
your browser set up to let you choose to accept cookies, then you <B>must</B>
accept the Moodle cookies, or Moodle won't work properly.)
<p>Now Moodle will start setting set up your database. Firstly, the main database
tables are created. You should see a number of SQL statements followed by
<p>Now Moodle will start setting up your database and creating tables to store data.
Firstly, the main database tables are created. You should see a number of SQL statements followed by
status messages (in green or red) that look like this:</p>
<blockquote>
<p>CREATE TABLE course ( id int(10) unsigned NOT NULL auto_increment, category
@@ -172,19 +229,28 @@
or the configuration settings you defined in config.php. Check that PHP isn't
in a restricted "safe mode" (commercial web hosts often have safe mode turned
on). You can check PHP variables by creating a little file containing &lt?
phpinfo ?&gt and looking at it through a browser. Check all these and try
phpinfo() ?&gt and looking at it through a browser. Check all these and try
this page again.</p>
<p>Scroll down the very bottom of the page and press the &quot;Continue&quot;
link.</p>
<p>Next you will see a similar page that sets up all the tables required by
each Moodle module. As before, they should all be green, otherwise you may
be a problem in the module code.</p>
each Moodle module. As before, they should all be green.</p>
<p>Scroll down the very bottom of the page and press the &quot;Continue&quot;
link.</p>
<p>You should now see a form where you can define more parameters for your Moodle
site, such as the name, the description shown on the front page, and so on.
<p>You should now see a form where you can define more configuration variables
for your installation, such as the default language, SMTP hosts and so on.
Don't worry too much about getting everything right just now - you can always
come back and edit these later on using the admin interface. Scroll down
to the bottom and click &quot;Save changes&quot;.</p>
<p>Next is a form where you can define parameters for your Moodle site and the
front page, such as the name, format, description and so on.
Fill this out (you can always go back and change these later) and then press
&quot;Save changes&quot;.</p>
<p>Finally, you will then be asked to create a top-level administration user
for future access to the admin pages. Fill out the details with your own name,
email etc and then click &quot;Save changes&quot;. Not all the fields are
@@ -225,7 +291,12 @@
where this script is run regularly (eg every five minutes). This provides
a &quot;heartbeat&quot; so that the script can perform functions at periods
defined by each module.</p>
<p>Test that the script works by running it directly from your browser:</p>
<P>Note that the machine performing the cron <B>does not need to be the same
machine that is running Moodle</B>. For example, if you have a limited web hosting
service that does not have cron, then you can might choose to run cron on another
server or on your home computer. All that matters is that the cron.php file is
called every five minutes or so.</p>
<p>First, test that the script works by running it directly from your browser:</p>
<blockquote>
<PRE>http://example.com/moodle/admin/cron.php</PRE>
</blockquote>
@@ -261,9 +332,8 @@
<PRE>*/5 * * * * wget -q -O /dev/null http://example.com/moodle/admin/cron.php</PRE>
</blockquote>
<p>On Windows systems: The simplest way is to use my package <A TITLE="Click to download this package (150k)" HREF="http://moodle.com/download/moodle-cron-for-windows.zip">moodle-cron-for-windows.zip</A>
which makes this whole thing very easy.</p>
<p>Other platforms: you will need to find another way to do this (please let
me know so I can update this documentation).<br>
which makes this whole thing very easy. You can also explore using the built-in
Windows feature for "Scheduled Tasks".</p>
</p>
</blockquote>
<H3><A NAME="course"></A>10. Create a new course</H3>
@@ -285,8 +355,7 @@
on course-building.</p>
</blockquote>
<P>&nbsp;</P>
<P ALIGN="CENTER"><FONT SIZE="1"><A HREF="index.html" TARGET="_top">Moodle Documentation</A></FONT></P>
<P ALIGN="CENTER"><FONT SIZE="1">Version: $Id: install.html,v 1.10 2002/08/16
08:33:54 martin Exp $</FONT></P>
<P ALIGN="CENTER"><FONT SIZE="1"><A HREF="." TARGET="_top">Moodle Documentation</A></FONT></P>
<P ALIGN="CENTER"><FONT SIZE="1">Version: $Id$</FONT></P>
</BODY>
+1 -1
View File
@@ -30,7 +30,7 @@
or teaching an online course.</P>
<P><BR>
</P>
<P ALIGN="CENTER"><FONT SIZE="1"><A HREF="index.html" TARGET="_top">Moodle Documentation</A></FONT></P>
<P ALIGN="CENTER"><FONT SIZE="1"><A HREF="." TARGET="_top">Moodle Documentation</A></FONT></P>
<P ALIGN="CENTER"><FONT SIZE="1">Version: $Id$</FONT></P>
</BODY>
+1 -1
View File
File diff suppressed because one or more lines are too long
+298
View File
@@ -0,0 +1,298 @@
<HEAD>
<TITLE>Moodle Docs: Release notes</TITLE>
<LINK REL="stylesheet" HREF="../theme/standard/styles.css" TYPE="TEXT/CSS">
<style type="text/css">
DT {font-family: "Trebuchet MS", Verdana, Arial, Helvetica, sans-serif; font-weight: bold;}
DD {margin-bottom:1em;}
</style>
</HEAD>
<BODY BGCOLOR="#FFFFFF">
<H2>Release notes</H2>
<H3> New in Moodle 1.0.7: </H3>
<UL><DL>
<DT> Simpler version numbers!</DT>
<DD> The four-digit version numbers were getting a bit ridiculous (too complex),
so I've switched back to simpler 3-digit numbers. The first digit is the
major structural version, the second digit is for decent-sized upgrades
and the third digit is for minor upgrades.</DD>
<DT> Languages</DT>
<DD> Two completely new languages have been added: Indonesian (from Arfan Hidayat)
and Japanese (from Mitsuhiro Yoshida). A US English version was added too.
Most other languages contain some updates. All languages now contain locale
information, which means that when a user changes the language all the dates
will display properly too.</DD>
<DT> Database access</DT>
<DD> ADOdb was upgraded to 2.50 which should fix some problems with very
new versions of PHP (4.3.0).</DD>
<DT> Layout improvements</DT>
<DD> Cleaned up the display of "side boxes" and added CSS style control over
more elements on the site and course pages. You may need to upgrade
your custom themes to get the full effect. Changes are in styles.php,
config.php and one line in header.html.
<P>The interface when
courses are on front page and there is more than one category has
been improved (no longer just shows short course names).</P>
</DD>
<DT> Class interface</DT>
<DD> A wrapper file provides a class interface to main Moodle library
(for external programs interfacing to Moodle) - moodle/lib/makeclass.php</DD>
<DT> Small improvements and bug fixes</DT>
<DD>
<LI> Quizzes now have a confirmation dialog when submitting an attempt
<LI> Courses now default to having "show recent activity" on (again).
<LI> Abolished leading zeroes in dates (introduced in last release)
<LI> Some formatting fixes for Japanese and old Netscape browsers
<LI> Teacher can allow larger assignments to be uploaded
<LI> Change password button on user page now always functions like the one on login page
<LI> Forum search now searches subjects as well as messages
<LI> Various HTML fixes
<LI> Fixes to grades display when there are no grades, also no forum ratings
<LI> Slashes in requested filenames are now stripped
<LI> Updates to the documentation
</DD>
</DL></UL>
<HR>
<H3> New in Moodle 1.0.6.4: </H3>
<UL><DL>
<DT> Authentication</DT>
<DD> Moodle now features seven different authentication mechanisms,
making it possible to hook Moodle up to nearly any external list
of users!</P>
<P>New methods just added include IMAP, POP3 and NNTP servers (including
those using SSL or certificate-based authentication), and also
authentication against user-specified fields in ANY
external database table.</P>
<P>The login page can now be partially customised
by the admin with personalised instructions, and the guest login can be
hidden if desired. </P>
<P>"Mappings" can be defined so that other fields (such as email, firstname,
lastname, department, language etc) can also be copied from LDAP or an
external database when accounts are first used.</P>
<P>Finally, Moodle now sports a cool
new admin GUI for configuring all of this, so it should be pretty
easy now to set up external authentication.
Many thanks to contributor Petri Asikainen for helping with the admin GUI.</P></DD>
<DT> Languages</DT>
<DD> Complete new Norwegian translation (from Jøran Sørbø), and updates for several others.</DD>
<DT> Assignments</DT>
<DD> Students can now resubmit assignments after grading if the teacher allows it</DD>
<DT> Contributed code</DT>
<DD> Standalone user-contributed code is now distributed under the /contrib directory. This directory
could get quite large, and the quality/security of it has usually not been checked by me,
and so this code is not included in the standard releases and nightlies. However, people
who are interested in it can access it via CVS (or see <A HREF="http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/moodle/moodle/contrib/">CVS web view</A>). As these new features become polished or if demand grows for them,
then I'll integrate them into the main Moodle distribution.
<BR><BR>
The first contributor is Holger Schadeck (compuproggy), who has written some <A HREF="http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/moodle/moodle/contrib/compuproggy/">interesting code</A> to help with translating all the Moodle help files. Check it out!</DD>
<DT> Bug fixes</DT>
<DD>
<LI> Day value in dates (eg forum posts, weekly listing) are
now displayed correctly on Windows servers.
<LI> config-dist.php and README.txt is now in DOS format to make it easier for Windows users to get started (Unix users shouldn't be affected).
<LI> Added a workaround (and new config switch in config-dist.php) for
some systems which have buggy referer variables. This should help
those people getting "stuck" on a form during setup.
<LI> Logout now sends you to the home page and clears the session completely.
<LI> Timezones now range between -13 to 13 hours (for daylight saving).
<LI> Character set in email now matches current language.
<LI> User pictures are now uploaded even if other fields have errors.
<LI> Full-size user pictures on user profile page no longer clickable.
<LI> Long user listing now has a small notice at the bottom about automatic unenrolment
<LI> Unenrol and change password buttons are hidden for guest student
<LI> Fixed occasional case where submitted assignments were sometimes having their owner changed.
<LI> User log graphs are now faster, cleaner and translatable.
<LI> Fixed HTML display errors with courses in category boxes on front page.
<LI> Admin and guest accounts now always work, even with external authentication activated.
<LI> Slightly more security when writing/reading files (now checks for embedded scripting).
<LI> The same user can now be deleted more than once (create, delete, recreate, delete caused error).
<LI> Language editor now works with multibyte languages (Thanks, Mits)
</DD>
</DL></UL>
<HR>
<H3> New in Moodle 1.0.6.3: </H3>
<UL><DL>
<DT> Bug fix for no-name forums.</DT>
<DD> New sites created with 1.0.6.2 had some forums appearing with no names
(for example the News forum on the home page).
A workaround is to add a new activity to that section (all the names
will be refreshed), but this release will fix it too. </DD>
<DT> New languages!</DT>
<DD> Catalan and Spanish (Spain) translations have arrived!</DD>
<DT> Some display improvements for old Netscape browsers (headers and quizzes)</DT>
<DT> Guest language now ALWAYS the same as the current site language</DT>
<DT> "Recent Activity" can now be disabled completely if desired </DT>
<DT> For very large classes (larger than 500) participant list is not displayed</DT>
</DL></UL>
<HR>
<H3> New in Moodle 1.0.6.2: </H3>
<UL><DL>
<DT> Course formatting improvements </DT>
<DD> The weekly and topic formats now have an extra "general" area up
the top where "general" activities are listed - these are things
that apply throughout the course, not just to one particular topic
or week. This general area is not shown if it is completely empty.</DD>
<DT> Popup "jump" menu. </DT>
<DD> You can now jump from one activity directly to any other using a
popup menu in the upper-right corner of the page</DD>
<DT> Speed improvements </DT>
<DD> Course activity details are now cached for each course, which
greatly reduces the amount of database access required to display
the course page. On heavily accessed systems this should improve speed.</DD>
<DT> Languages </DT>
<DD> Surveys are now completely translatable.</DD>
<DT> Admin improvements </DT>
<DD> Paging was added to the user admin page, so that the admin can now
browse large numbers of users. </DD>
<DT> Fixes and tweaks </DT>
<DD> Various other small improvements to formatting</DD>
</DL></UL>
<HR>
<H3> New in Moodle 1.0.6.1: </H3>
<UL><DL>
<DT> New assignment type: offline assignments </DT>
<DD> In addition to "upload a file" assignments, you can now have "offline"
assignments. These don't require the student to do anything online.
They are useful for grading activities that are not on in Moodle, and a
also useful for adding "manual" columns to the grade page.</DD>
<DT> Languages </DT>
<DD> Spanish (Mexican) has been added to the distribution. Other languages have various improvements.</DD>
<DT> SMTP authentication </DT>
<DD> SMTP mail now supports SMTP username and password if needed</DD>
<DT> Documentation </DT>
<DD> Some parts rewritten, and documentation cleaned up (upgrade info now part of main docs)</DD>
<DT> Other fixes </DT>
<UL><LI>Better checking on teachers using "loginas" to stop them roaming other courses as a student
<LI>While using "loginas", teachers can return to their own identity using a link in the footer
<LI>Some strings fixed in assignments, journals, and forums.
<LI>Guest language is now the same as the site
<LI>etc
</UL></DD>
</DL></UL>
<HR>
<H3> New in Moodle 1.0.6: </H3>
<UL><DL>
<DT> New feature - WYSIWYG Text editing! </DT>
<DD> A WYSIWYG text editor has been added to many of the forms in Moodle. These are currently
only visible when using Microsoft Internet Explorer 5.5 or later - other browsers see the
normal forms exactly as before.</DD>
<DT> New feature - Quiz module! </DT>
<DD> Finally, the most requested new module is here! Multiple choice, short answer, and true-false
questions with automatic marking, multiple attempts, teacher regrading and many other features.
Questions are stored in a categorised database, and may be "published" to other courses.</DD>
<DT> New feature - Grade manager! </DT>
<DD> A new tool has been added for teachers to see all grades for a course on one page.
You can also download/export grades as a tab-separated text file or an Excel
Spreadsheet. In future more features will be added to this page like sorting, manual
columns and calculations, but it's still pretty useful right now.</DD>
<DT> New feature - LDAP authentication! </DT>
<DD> Moodle can now authenticate against external directories that use the
LDAP protocol (including Novell etc). Many thanks to Petri Asikainen for
developing this authentication plug-in!</DD>
<DT> New feature - New smilies </DT>
<DD> Many new smilies have been added, and are now also accessible using a GUI in the text editor.</DD>
<DT> Improved text editing </DT>
<DD> You can now include all major HTML tags in all texts. This is now safe because
of newly added functionality that strips all Javascript and faulty tags from texts
before they can cause security or display problems.</DD>
<DT> Languages </DT>
<DD> German and Italian have been added! Many thanks to the translators (see the credits).</DD>
<DT> Reading module => Resource module </DT>
<DD> After much thought and a vote of support (21 "yes" to 6 "no") on the "Using Moodle"
web site I changed the name of the "reading" module to "resource" (at the code level
and also the language packs). It was better to do this earlier than later.
This more generic name will be more meaningful to more people and opens the way to
some real development on a resource library.
But I don't want to ever change a module name again! :-)
If you have any hard-coded URLs pointing to readings that you don't want to break,
you can add a line like this to your Apache httpd.conf to redirect them:
<P><CODE>Redirect /mod/reading http://yourserver.com/mod/resource</CODE></P>
<FONT COLOR=RED>Note: if upgrading to 1.0.6 you may have some "reading" errors in "Recent activity" ... logging
out and then logging in again will fix this</FONT></DD>
<DT> Other additions </DT>
<DD> An admin script to totally delete the Moodle data directory has been included (admin/delete.php)
for people who need to tear down a Moodle installation but don't have root access on their
server.</DD>
<DT> Miscellaneous </DT>
<DD> Many small improvements have been made to the interface, and many small bugs have been fixed.
Some examples:
<UL>
<LI> Big "Edit this page" buttons at the top of pages (replacing the tiny icon)
<LI> LDAP authentication module (thanks to Petri)
<LI> Authentication from external sources can now import any fields
<LI> Student assignment list now shows submission status properly
<LI> Default language for users is now the site language
<LI> Users have a 'Change Password' button on their profile page
<LI> Journals that need teacher feedback are highlighted
<LI> More documentation and more context help buttons
<LI> Database-specific upgrade code
<LI> Uses character-set codes to make the browser do the right thing
<LI> User's name in footer is now a link
<LI> News and social forums are now editable
<LI> Forums that don't allow posting don't have uneccessary "discuss" links
<LI> Improved algorithm for shortening posts in forum listings
<LI> Choice module now allows up to six choices
</UL>
</DD>
</DL></UL>
<P>&nbsp;</P>
<P ALIGN="CENTER"><FONT SIZE="1"><A HREF="../doc/" TARGET="_top">Moodle Documentation</A></FONT></P>
<P ALIGN="CENTER"><FONT SIZE="1">Version: $Id$</FONT></P>
+20 -9
View File
@@ -92,7 +92,7 @@
<p align="center"><img src="pix/files.jpg" width="400" height="347"></p>
<p>&nbsp;</p>
<p>This interface is only available to teachers - it is not accessible by students.
Individual files are made available to students later on (as &quot;Readings&quot;
Individual files are made available to students later on (as &quot;Resources&quot;
- see the next section).</p>
<p>As you can see in the screenshot, files are listed alongside subdirectories.
You can create any number of subdirectories to organise your files and move
@@ -109,7 +109,7 @@
with the same name as an existing file it will automatically be overwritten.</p>
<p>A final note: if your content resides out on the web then you don't need
to upload the files at all - you can link directly to them from inside the
course (see the Readings module and the next section).</p>
course (see the Resources module and the next section).</p>
<HR>
</blockquote>
<H3><A NAME="activities"></A>Setting up activities</H3>
@@ -135,7 +135,7 @@
<BR>
<dt><strong>Choice</strong></dt>
<dd>A choice activity is very simple - you ask a question and specify a choice
of responses (currently only two). Students can make that choice, and you
of responses. Students can make their choice, and you
have a report screen where you can see the results. I use it to gather research
consent from my students, but you could use it for quick polls or class
votes.</dd>
@@ -158,12 +158,23 @@
and students will receive an automatic email informing them of your feedback.</dd>
<BR>
<BR>
<dt><strong>Reading</strong></dt>
<dd>Readings are the content of your course. Each reading can be any file
<dt><strong>Resource</strong></dt>
<dd>Resources are the content of your course. Each resource can be any file
you have uploaded or can point to using a URL. You can also maintain simple text-based pages by typing them
directly into a form.</dd>
<BR>
<BR>
<dt><strong>Quiz</strong></dt>
<dd>This module allows you to design and set quiz tests, consisting of
multiple choice, true-false, and short answer questions. These
questions are kept in a categorised database, and can be re-used
within courses and even between courses. Quizzes can allow
multiple attempts. Each attempt is automatically marked, and the
teacher can choose whether to give feedback or to show correct answers.
This module includes grading facilities.
</dd>
<BR>
<BR>
<dt><strong>Survey</strong></dt>
<dd>The survey module provides a number of predefined survey instruments that are useful in
evaluating and understanding your class. Currently they include the COLLES and the ATTLS instruments.
@@ -181,7 +192,7 @@
<H3><A NAME="course"></A>Running the course</H3>
<blockquote>
<p>I could write a thesis about this. Actually I <strong>am</strong> writing
a thesis about this. <img src="../pix/s/biggrin.gif" width="16" height="16"></p>
a thesis about this. <img src="../pix/s/biggrin.gif" width="15" height="15"></p>
<p>Until then here are just a few quick pointers:</p>
<ol>
<li>Subscribe yourself to all the forums.</li>
@@ -210,8 +221,8 @@
local site administrator.</p>
<p>If you have some great ideas for improvements to Moodle, or even some good
stories, come over to <a href="http://moodle.com/" target="_top">moodle.com</a> and join
in the Teacher's forum on that site. We'd love to hear them, and you can help
Moodle improve.</p>
in the course called "<A HREF="http://moodle.com/course/view.php?id=5" target=_top >Using Moodle</A>".
We'd love to hear from you, and you can help Moodle improve.</p>
<p>If you want to contribute to coding new modules, or writing documentation,
or papers, contact me: <a href="http://dougiamas.com/" target="_top">Martin
Dougiamas</a> or browse the &quot;bug tracker&quot; site for Moodle, at <a href="http://bugs.moodle.com" target="_top">bugs.moodle.com</a></p>
@@ -219,7 +230,7 @@
<HR>
<p>&nbsp;</p>
</blockquote>
<P ALIGN="CENTER"><FONT SIZE="1"><A HREF="index.html" TARGET="_top">Moodle Documentation</A></FONT></P>
<P ALIGN="CENTER"><FONT SIZE="1"><A HREF="." TARGET="_top">Moodle Documentation</A></FONT></P>
<P ALIGN="CENTER"><FONT SIZE="1">Version: $Id: teacher.html,v 1.4 2002/08/18 10:00:01
martin Exp $</FONT></P>
+12
View File
@@ -0,0 +1,12 @@
<?PHP // $Id$
require("../config.php");
if (! $site = get_site()) {
error("Site is misconfigured");
}
$strdocumentation = get_string("documentation");
print_header("$site->shortname: $strdocumentation", "$site->fullname", "$strdocumentation", "", "", true, "", navmenu($site));
?>
+110
View File
@@ -0,0 +1,110 @@
<HEAD>
<TITLE>Moodle Docs: Upgrading</TITLE>
<LINK REL="stylesheet" HREF="../theme/standard/styles.css" TYPE="TEXT/CSS">
</HEAD>
<BODY BGCOLOR="#FFFFFF">
<H2>Upgrading Moodle</H2>
<p>Moodle is designed to upgrade cleanly from any earlier version to any later
version. </p>
<p>When upgrading a Moodle installation you should follow these steps:</p>
<h2>1. Backup important data</h2>
<blockquote>
<p>Although it is not strictly necessary, it is always a good idea to make a
backup of any production system before a major upgrade, just in case you need
to revert back to the older version for some reason. In fact, it's a good
idea to automate your server to backup your Moodle installation daily, so
that you can skip this step.</p>
<p>There are three areas that need backing up:</p>
<blockquote>
<p><strong>1. The Moodle software directory itself</strong></p>
<blockquote>
<p>Make a separate copy of these files before the upgrade, so that you can
retrieve your config.php and any modules you have added like themes, languages
etc<strong><br>
</strong></p>
</blockquote>
<p><strong>2. Your data directory.</strong></p>
<blockquote>
<p>This is where uploaded content resides (such as course resources and
student assignments) so it is very important to have a backup of these
files anyway. Sometimes upgrades may move or rename directories within
your data directory.<strong><br>
</strong></p>
</blockquote>
<p><strong>3. Your database</strong></p>
<blockquote>
<p>Most Moodle upgrades will alter the database tables, adding or changing
fields. Each database has different ways to backup. One way of backing
up a MySQL database is to 'dump' it to a single SQL file. The following
example shows Unix commands to dump the database called &quot;moodle&quot;:</p>
<blockquote>
<p><font face="Courier New, Courier, mono">mysqldump moodle &gt; moodle-backup-2002-10-26.sql</font></p>
</blockquote>
<p>You can also use the &quot;Export&quot; feature in Moodle's &quot;Manage
Database&quot; web interface to do the same thing on all platforms.</p>
</blockquote>
</blockquote>
</blockquote>
<h2>&nbsp;</h2>
<h2>2. Install the new Moodle software</h2>
<blockquote>
<p><strong>Using a downloaded archive</strong></p>
<blockquote>
<p>Do not overwrite an old installation unless you know what you are doing
... sometimes old files can cause problems in new installations. The best
way it to rename the current Moodle directory to something else, then unpack
the new Moodle archive into the old location.</p>
<blockquote>
<p><font face="Courier New, Courier, mono">mv moodle moodle.backup<br>
tar xvzf moodle-1.0.6.tgz</font></p>
</blockquote>
<p>Next, copy across your config.php and any other plugins such as custom
themes:</p>
<blockquote>
<p><font face="Courier New, Courier, mono">cp moodle.backup/config.php moodle<br>
cp -pr moodle.backup/theme/mytheme moodle/theme/mytheme</font></p>
</blockquote>
</blockquote>
<p><strong>Using CVS</strong></p>
<blockquote>
<p>If you are using CVS, just go into the Moodle root directory and update
to the new files:</p>
<blockquote>
<p><font face="Courier New, Courier, mono">cvs update -dP</font></p>
</blockquote>
<p>Make sure you use the &quot;d&quot; parameter to create new directories
if necessary, and the &quot;P&quot; parameter to prune empty directories.</p>
<p>If you have been editing Moodle files, watch the messages very closely
for possible conflicts. All your customised themes and non-standard plugins
will be untouched.</p>
</blockquote>
<p>&nbsp;</p>
</blockquote>
<h2>3. Finishing the upgrade</h2>
<blockquote>
<p>The last step is to trigger the upgrade processes within Moodle.</p>
<p>To do this just visit <a target=_top href="../admin/index.php">the admin page of your
installation</a>.</p>
<blockquote>
<p><font face="Courier New, Courier, mono">http://example.com/moodle/admin</font></p>
</blockquote>
<p>It doesn't matter if you are logged in as admin or not.</p>
<p> Moodle will automatically detect the new version and perform all the database
or filesystem upgrades that are necessary. If there is anything it can't do
itself (very rare) then you will see messages telling you what you need to
do. </p>
</blockquote>
<p>&nbsp; </p>
<p> Assuming all goes well (no error messages) then you can start using your new
version of Moodle and enjoy the new features!</p>
<p>If you have trouble with the upgrade, visit <a target=_top href="http://moodle.com/">moodle.com</a>
and post on the <a target=_top href="http://moodle.com/mod/forum/view.php?id=28">Installation
Support Forum</a>.</p>
<p>&nbsp;</p>
<P>&nbsp;</P>
<P ALIGN="CENTER"><FONT SIZE="1"><A HREF="." TARGET="_top">Moodle Documentation</A></FONT></P>
<P ALIGN="CENTER"><FONT SIZE="1">Version: $Id$</FONT></P>
</BODY>
+22 -13
View File
@@ -2,27 +2,36 @@
require("../config.php");
require_variable($id); // course context
optional_variable($id); // course context
require_variable($file); // file in this directory to view
if (! $course = get_record("course", "id", $id)) {
error("Course is misconfigured");
}
if (!isteacher($course->id)) {
error("Only teachers can look at this page");
}
$file = clean_filename($file);
if (file_exists($file)) {
if (!file_exists($file)) {
error("404 - File not found");
}
if ($id) {
if (! $course = get_record("course", "id", $id)) {
error("Course is misconfigured");
}
$strhelp = get_string("help");
print_header("$course->shortname: $strhelp", "$course->fullname",
"<A HREF=\"../course/view.php?id=$course->id\">$course->shortname</A> -> $strhelp");
echo "<BLOCKQUOTE>";
include($file);
echo "</BLOCKQUOTE>";
} else {
if (! $site = get_site()) {
error("Site is misconfigured");
}
$strdocumentation = get_string("documentation");
print_header("$site->shortname: $strhelp", "$site->fullname",
"<A HREF=\"view.php?file=contents.html\">$strdocumentation</A>");
}
echo "<BLOCKQUOTE>";
include($file);
echo "</BLOCKQUOTE>";
?>
+5 -3
View File
@@ -12,10 +12,12 @@
redirect("$CFG->wwwroot/course/", "Message sent, thanks", 3);
die;
}
print_header("$CFG->sitename:Error", "$CFG->sitename: Error 404", "", "form.text");
print_simple_box("An unusual error occurred (tried to reach a page that doesn't exist).<P align=center>$REQUEST_URI", "center", "", "$THEME->cellheading");
$site = get_site();
print_header("$site->fullname:Error", "$site->fullname: Error 404", "", "form.text");
print_simple_box("An unusual error occurred (tried to reach a page that doesn't exist).<P align=center>$REDIRECT_URL", "center", "", "$THEME->cellheading");
?>
+4 -1
View File
@@ -15,7 +15,10 @@
error("This script DEPENDS on PATH_INFO being available. Read the README.");
}
$args = get_slash_arguments();
if (! $args = get_slash_arguments()) {
error("No valid arguments supplied");
}
$numargs = count($args);
$courseid = (integer)$args[0];
+2 -2
View File
@@ -547,7 +547,7 @@ function displaydir ($wdir) {
$filename = $fullpath."/".$dir;
$fileurl = rawurlencode($wdir."/".$dir);
$filesafe = rawurlencode($dir);
$filedate = userdate(filectime($filename), "%e %b %Y, %I:%M %p");
$filedate = userdate(filectime($filename), "%d %b %Y, %I:%M %p");
echo "<TR>";
@@ -573,7 +573,7 @@ function displaydir ($wdir) {
$fileurl = "$wdir/$file";
$filesafe = rawurlencode($file);
$fileurlsafe = rawurlencode($fileurl);
$filedate = userdate(filectime($filename), "%e %b %Y, %I:%M %p");
$filedate = userdate(filectime($filename), "%d %b %Y, %I:%M %p");
echo "<TR>";
+1
View File
@@ -12,6 +12,7 @@ function mimeinfo($element, $filename) {
"html" => array ("type"=>"text/html", "icon"=>"html.gif"),
"htm" => array ("type"=>"text/html", "icon"=>"html.gif"),
"txt" => array ("type"=>"text/plain", "icon"=>"text.gif"),
"php" => array ("type"=>"text/plain", "icon"=>"text.gif"),
"wav" => array ("type"=>"audio/wav", "icon"=>"audio.gif"),
"mp3" => array ("type"=>"audio/mp3", "icon"=>"audio.gif"),
"au" => array ("type"=>"audio/au", "icon"=>"audio.gif"),
+6 -2
View File
@@ -10,6 +10,8 @@
optional_variable($text, "No text to display");
optional_variable($module, "moodle");
$lang = current_language();
print_header();
if (ereg("\\.\\.", $file)) {
@@ -18,9 +20,9 @@
if ($file) {
if ($module == "moodle") {
$filepath = "$CFG->dirroot/lang/$CFG->lang/help/$file";
$filepath = "$CFG->dirroot/lang/$lang/help/$file";
} else {
$filepath = "$CFG->dirroot/lang/$CFG->lang/help/$module/$file";
$filepath = "$CFG->dirroot/lang/$lang/help/$module/$file";
}
if (file_exists("$filepath")) {
@@ -45,6 +47,8 @@
echo $text;
echo "</P>";
}
close_window_button();
?>
</BODY>
</HTML>
+31 -31
View File
@@ -1,39 +1,39 @@
<? // $Id$
// index.php - the front page.
<?PHP // $Id$
// index.php - the front page.
require("config.php");
include("course/lib.php");
include("mod/reading/lib.php");
include("mod/forum/lib.php");
require("course/lib.php");
require("mod/resource/lib.php");
require("mod/forum/lib.php");
if (! $site = get_site()) {
redirect("$CFG->wwwroot/admin/");
redirect("$CFG->wwwroot/admin/index.php");
}
if (isadmin()) {
if (moodle_needs_upgrading()) {
redirect("$CFG->wwwroot/admin/");
redirect("$CFG->wwwroot/admin/index.php");
}
$headerbutton = update_course_icon($site->id);
} else {
if (isset($USER->id)) {
$headerbutton = "<FONT SIZE=2><A HREF=\"$CFG->wwwroot/login/logout.php\">".get_string("logout")."</A></FONT>";
} else {
$headerbutton = "<FONT SIZE=2><A HREF=\"$CFG->wwwroot/login/\">".get_string("login")."</A></FONT>";
$headerbutton = "<FONT SIZE=2><A HREF=\"$CFG->wwwroot/login/index.php\">".get_string("login")."</A></FONT>";
}
}
print_header("$site->fullname", "$site->fullname", "", "",
print_header("$site->fullname", "$site->fullname", "home", "",
"<META NAME=\"Description\" CONTENT=\"".stripslashes(strip_tags($site->summary))."\">",
true, $headerbutton);
true, "", $headerbutton);
$side = 180;
$side = 175;
?>
<TABLE WIDTH="100%" BORDER="0" CELLSPACING="5" CELLPADDING="5">
<TR>
<?
<?PHP
$sections = get_all_sections($site->id);
if ($site->newsitems > 0 or $sections[0]->sequence or isediting($site->id)) {
@@ -42,23 +42,18 @@
if ($sections[0]->sequence or isediting($site->id)) {
get_all_mods($site->id, $mods, $modnames, $modnamesplural, $modnamesused);
print_simple_box(get_string("mainmenu"), "CENTER", $side, "$THEME->cellheading");
}
if ($sections[0]->sequence) {
print_section($site->id, $sections[0], $mods, $modnamesused, true, $side);
}
if (isediting($site->id)) {
echo "<DIV ALIGN=right>";
popup_form("$CFG->wwwroot/course/mod.php?id=$site->id&section=0&add=",
$modnames, "section0", "", get_string("add")."...");
echo "</DIV>";
print_section_block(get_string("mainmenu"), $site, $sections[0],
$mods, $modnames, $modnamesused, true, $side, isediting($site->id));
}
if ($site->newsitems > 0 ) {
print_simple_box(get_string("courses"), "CENTER", $side, "$THEME->cellheading");
print_all_courses($cat=1, "minimal", 10);
$categories = get_all_categories();
if (count($categories) > 1) {
print_course_categories($categories, "none", $side);
} else {
$category = array_shift($categories);
print_all_courses($category->id, "minimal", 10, $side);
}
}
print_spacer(1,$side);
}
@@ -76,9 +71,14 @@
echo "<TD WIDTH=70% VALIGN=TOP>";
if ($site->newsitems == 0 ) {
print_simple_box(get_string("availablecourses"), "CENTER", "100%", "$THEME->cellheading");
print_heading_block(get_string("availablecourses"));
print_spacer(8,1);
print_all_courses();
$categories = get_all_categories();
if (count($categories) > 1) {
print_course_categories($categories, "index");
} else {
print_all_courses("all");
}
} else {
if (! $newsforum = forum_get_course_forum($site->id, "news")) {
@@ -101,7 +101,7 @@
} else {
$headertext = get_string("sitenews");
}
print_simple_box($headertext, "CENTER", "100%", $THEME->cellheading);
print_heading_block($headertext);
print_spacer(8,1);
forum_print_latest_discussions($newsforum->id, $site->newsitems);
}
@@ -113,7 +113,7 @@
$site->summary .= "<BR><CENTER><A HREF=\"admin/site.php\"><IMG SRC=\"pix/i/edit.gif\" BORDER=0></A>";
}
print_simple_box($site->summary, "", "100%", $THEME->cellheading);
print_simple_box($site->summary, "", "100%", $THEME->cellcontent2);
print_spacer(1,$side);
echo "</TD>";
?>
@@ -121,5 +121,5 @@
</TR>
</TABLE>
<? print_footer("home"); // Please do not modify this line ?>
<?PHP print_footer("home"); // Please do not modify this line ?>
+30
View File
@@ -0,0 +1,30 @@
<?PHP // $Id$
// assignment.php - created with Moodle 1.0.5 dev (2002092300)
$string['assignmentdetails'] = "Assignment details";
$string['assignmentname'] = "ãåãÉ";
$string['assignmenttype'] = "Assignment type";
$string['description'] = "Description";
$string['duedate'] = "Due date";
$string['early'] = "\$a early";
$string['failedupdatefeedback'] = "Failed to update submission feedback for user \$a";
$string['feedbackupdated'] = "Submissions feedback updated for \$a people";
$string['late'] = "\$a late";
$string['maximumgrade'] = "Maximum grade";
$string['maximumsize'] = "Maximum size";
$string['modulename'] = "ãåãÉ";
$string['modulenameplural'] = "Assignments";
$string['newsubmissions'] = "Assignments submitted";
$string['notsubmittedyet'] = "Not submitted yet";
$string['overwritewarning'] = "Warning: uploading again will REPLACE your current submission";
$string['submissionfeedback'] = "Submission feedback";
$string['submissions'] = "Submissions";
$string['submitassignment'] = "Submit your assignment using this form";
$string['submitted'] = "Submitted";
$string['typeuploadsingle'] = "Upload a single file, worth between 0 - 100 marks";
$string['uploadedfiles'] = "uploaded files";
$string['viewsubmissions'] = "View \$a submitted assignments";
$string['yoursubmission'] = "Your submission";
?>
+17
View File
@@ -0,0 +1,17 @@
<?PHP // $Id$
#------------------------------------------------------------
$string['modulename'] = "ÇÓÊÈíÇä";
$string['modulenameplural'] = "ÇÓÊÈíÇäÇÊ";
#------------------------------------------------------------
$string['answered'] = "Answered";
$string['choice'] = "Choice \$a";
$string['choicename'] = "Choice name";
$string['choicetext'] = "Choice text";
$string['notanswered'] = "Not answered yet";
$string['responses'] = "Responses";
$string['responsesto'] = "Responses to \$a";
$string['savemychoice'] = "Save my choice";
$string['viewallresponses'] = "View \$a responses";
?>
+116
View File
@@ -0,0 +1,116 @@
<?PHP // $Id$
#------------------------------------------------------------
$string['modulename'] = "ÓÇÍÉ ÇáÍæÇÑ";
$string['modulenameplural'] = "Forums";
#------------------------------------------------------------
$string['addanewdiscussion'] = "Add a new discussion topic";
$string['allowchoice'] = "Allow everyone to choose";
$string['allowdiscussions'] = "Can a \$a post to this forum?";
$string['allowratings'] = "Allow posts to be rated?";
$string['allowsdiscussions'] = "This forum allows each person to start one discussion topic.";
$string['anyfile'] = "Any file";
$string['attachment'] = "Attachment";
$string['bynameondate'] = "by \$a->name - \$a->date";
$string['couldnotadd'] = "Could not add your post due to an unknown error";
$string['couldnotdeleteratings'] = "Sorry, that cannot be deleted as people have already rated it";
$string['couldnotdeletereplies'] = "Sorry, that cannot be deleted as people have already responded to it";
$string['couldnotupdate'] = "Could not update your post due to an unknown error";
$string['delete'] = "Delete";
$string['deleteddiscussion'] = "The discussion topic has been deleted";
$string['deletedpost'] = "The post has been deleted";
$string['deletesure'] = "Are you sure you want to delete this post?";
$string['discussion'] = "Discussion";
$string['discussions'] = "Discussions";
$string['discussionsstartedby'] = "Discussions started by \$a";
$string['discussthistopic'] = "Discuss this topic";
$string['eachuserforum'] = "Each person posts one discussion";
$string['edit'] = "Edit";
$string['editing'] = "Editing";
$string['emptymessage'] = "Something was wrong with your post. Perhaps you left it blank, or the attachment was too big. Your changes have NOT been saved.";
$string['everyonecanchoose'] = "Everyone can choose to be subscribed";
$string['everyoneissubscribed'] = "Everyone is subscribed to this forum";
$string['forcesubscribe'] = "Force everyone to be subscribed";
$string['forcesubscribeq'] = "Force everyone to be subscribed?";
$string['forum'] = "Forum";
$string['forumintro'] = "Forum introduction";
$string['forumname'] = "Forum name";
$string['forums'] = "Forums";
$string['forumtype'] = "Forum type";
$string['generalforum'] = "Standard forum for general use";
$string['generalforums'] = "General forums";
$string['inforum'] = "in \$a";
$string['intronews'] = "General news and announcements";
$string['introsocial'] = "An open forum for chatting about anything you want to";
$string['introteacher'] = "A forum for teacher-only notes and discussion";
$string['learningforums'] = "Learning forums";
$string['maxtimehaspassed'] = "Sorry, but the maximum time for editing this post (\$a) has passed!";
$string['message'] = "Message";
$string['modeflatoldestfirst'] = "Display replies flat, with oldest first";
$string['modeflatnewestfirst'] = "Display replies flat, with newest first";
$string['modenested'] = "Display replies in nested form";
$string['modethreaded'] = "Display replies in threaded form";
$string['more'] = "more";
$string['namenews'] = "News forum";
$string['namesocial'] = "Social forum";
$string['nameteacher'] = "Teacher forum";
$string['newforumposts'] = "New forum posts";
$string['nodiscussions'] = "There are no discussion topics yet in this forum";
$string['noguestpost'] = "Sorry, guests are not allowed to post";
$string['noposts'] = "No posts";
$string['nosubscribers'] = "There are no subscribers yet for this forum";
$string['nownotsubscribed'] = "\$a->name will NOT receive copies of '\$a->forum' by email.";
$string['nowsubscribed'] = "\$a->name will receive copies of '\$a->forum' by email.";
$string['numposts'] = "\$a posts";
$string['olderdiscussions'] = "Older discussions";
$string['openmode0'] = "No discussions, no replies";
$string['openmode1'] = "No discussions, but replies are allowed";
$string['openmode2'] = "Discussions and replies are allowed";
$string['parentofthispost'] = "Parent of this post";
$string['postadded'] = "Your post was successfully added.<P>You have \$a to edit it if you want to make any changes.";
$string['postmailinfo'] = "This is a copy of a message posted on the \$a website.
To add your reply via the website, click on this link:";
$string['postingtip'] = "<B>Posting tips:</B>
When replying:
<UL>
<LI>read their post carefully and empathically
<LI>look for things you can comment on
</UL>
While writing:
<UL>
<LI>keep your posts short and on-topic
<LI>explain your own ideas clearly
<LI>think of questions you can ask
</UL>";
$string['postrating1'] = "Shows mostly SEPARATE knowing";
$string['postrating2'] = "Equally separate and connected";
$string['postrating3'] = "Shows mostly CONNECTED knowing";
$string['postupdated'] = "Your post was updated";
$string['processingpost'] = "Processing post \$a";
$string['rate'] = "Rate";
$string['ratings'] = "Ratings";
$string['readtherest'] = "Read the rest of this topic";
$string['re'] = "Re:"; // Put in front of subjects that are replies to another post
$string['repliesmany'] = "\$a replies so far";
$string['repliesone'] = "\$a reply so far";
$string['reply'] = "Reply";
$string['search'] = "Search";
$string['searchforums'] = "Search forums";
$string['sendinratings'] = "Send in my latest ratings";
$string['showsubscribers'] = "Show subscribers";
$string['singleforum'] = "A single simple discussion";
$string['subject'] = "Subject";
$string['subscribe'] = "Subscribe to this forum";
$string['subscribed'] = "Subscribed";
$string['subscribers'] = "Subscribers";
$string['subscribersto'] = "Subscribers to '\$a'";
$string['unsubscribe'] = "Unsubscribe from this forum";
$string['youratedthis'] = "You rated this";
$string['yournewtopic'] = "Your new discussion topic";
$string['yourreply'] = "Your reply";
?>
+29
View File
@@ -0,0 +1,29 @@
<?PHP // $Id$
#------------------------------------------------------------
$string['modulename'] = "ÃÎÈÇÑ";
$string['modulenameplural'] = "ÃÎÈÇÑ";
#------------------------------------------------------------
$string['alwaysopen'] = "Always open";
$string['blankentry'] = "Blank entry";
$string['daysavailable'] = "Days available";
$string['editingends'] = "Editing period ends";
$string['editingended'] = "Editing period has ended";
$string['journalname'] = "Journal name";
$string['journalquestion'] = "Journal question";
$string['journalrating1'] = "Not satisfactory";
$string['journalrating2'] = "Satisfactory";
$string['journalrating3'] = "Outstanding";
$string['newjournalentries'] = "New journal entries";
$string['noentry'] = "No entry";
$string['notopenuntil'] = "This journal won't be open until";
$string['notstarted'] = "You have not started this journal yet";
$string['noratinggiven'] = "No rating given";
$string['overallrating'] = "Overall rating";
$string['rate'] = "Rate";
$string['startoredit'] = "Start or edit my journal entry";
$string['viewallentries'] = "View \$a journal entries";
?>
+477
View File
@@ -0,0 +1,477 @@
<?PHP // $Id$
$string['thislanguage'] = "Arabic"; // Name of this language in the native language eg Français
$string['thischarset'] = "windows-1256"; // The best charset to use for this language
$string['action'] = "إجراء";
$string['activity'] = "نشاط";
$string['activities'] = "أنشطة";
$string['activityreport'] = "تقرير النشاط";
$string['add'] = "إضافة";
$string['added'] = "تمت إضافة \$a";
$string['addinganew'] = "إضافة \$a جديد";
$string['addinganewto'] = "إضافة \$a->what \$a->to جديد إلى";
$string['addnewcourse'] = "إضافة منهج دراسي جديد";
$string['addnewuser'] = "إضافة مستخدم جديد";
$string['address'] = "عنوان";
$string['addteacher'] = "إضافة مدرس";
$string['admin'] = "Admin";
$string['administration'] = "الإدارة";
$string['again'] = "مرة أخرى";
$string['all'] = "الكل";
$string['alldays'] = "كل الأيام";
$string['allfieldsrequired'] = "كل الحقول مطلوبة";
$string['alllogs'] = "كل ملفات السجلات";
$string['allowguests'] = "يسمح للمستخدمين الضيوف بالدخول إلى هذا المنهج الدراسي";
$string['allparticipants'] = "كل المشاركين";
$string['alphanumerical'] = "لا يقبل إلا حروف هجائية أو أرقام";
$string['alreadyconfirmed'] = "تم تأكيد التسجيل بالفعل";
$string['answer'] = "إجابة";
$string['assignteachers'] = "تعيين مدرسين";
$string['availablecourses'] = "المناهج الدراسية المتوفرة";
$string['cancel'] = "إلغاء";
$string['categories'] = " المناهج الدراسية";
$string['category'] = "نوعية";
$string['categoryadded'] = "النوعية '\$a' أضيفت";
$string['categorydeleted'] = "النوعية '\$a' حذفت";
$string['changepassword'] = "قم بتغيير كلمة المرور";
$string['changedpassword'] = "تم تغيير كلمة المرور";
$string['changessaved'] = "تم حفظ التغييرات";
$string['checklanguage'] = "اختيار اللغة";
$string['choose'] = "اختيار";
$string['choosecourse'] = "اختيار منهج دراسي";
$string['chooselivelogs'] = "أو شاهد النشاط الحالي";
$string['chooselogs'] = "اختر ملفات السجلات التي تريد الإطلاع عليها";
$string['choosetheme'] = "اختر موضوعا";
$string['chooseuser'] = "اختر مستخدما";
$string['city'] = "المدينة/البلدة";
$string['comparelanguage'] = "قارن وعدل اللغة الحالية";
$string['configauth'] = "اختر وحدة التوثيق النمطية التي تريد استخدامها. الوضع الافتراضي هو 'email' ويتمتع بأعلى حماية. الأسلوب 'none' ليس به أي شكل من أشكال الاختبار - لذا ينصح بالحذر عند استخدامه إلا إذا كنت متمرسا.";
$string['configgdversion'] = "عين النسخة التي تم تنصيبها من GD. النسخة المعروضة افتراضيا هي التي يتم الكشف عنها آليا. لا تقم بتغيير هذا الوضع إلا إذا كنت متمرسا.";
$string['configerrorlevel'] = "اختر عدد تحذيرات PHP التي تريد إظهارها. المعدل العادي هو أفضل الخيارات غالبا.";
$string['configintro'] = "في هذه الصفحة تستطيع تحديد عدد متغيرات التكوين التي تساعد على عمل Moodle بشكل جيد على مزودك. لا تقلق بشأن ذلك، فالأوضاع الافتراضية تعمل بشكل جيد في الغالب، كما أن باستطاعتك أن تغير هذه الإعدادات لاحقا من خلال هذه الصفحة.";
$string['configlang'] = "اختر لغة افتراضية للموقع بأكمله، مع العلم أن المستخدمين لديهم القدرة على استبدال هذه الإعدادات بأخرى لاحقا.";
$string['configlocale'] = "اختر موقعا للموقع بأكمله. مع العلم أن هذه سيؤثر في تواريخ العرض. وسوف تحتاج إلى تنصيب بيانات الموقع على نظام التشغيل الخاص بك. إذا كنت لا تعرف أي الخيارات أنسب، دع المكان خاليا.";
$string['configlongtimenosee'] = "إذا لم يتم دخول الطلاب لفترة طويلة، فسيؤدي ذلك إلى إلغاء اشتراكهم من حلقات الدراسة أتوماتيكيا. هذا المعامل يحدد المهلة الزمنية لذلك.";
$string['configmaxeditingtime'] = "هذا يقوم بتحديد المهلة الزمنية المطلوبة لإعادة تحرير مراسلات المنتدىات وتقارير السجلات، إلخ. وتعد فترة 30 دقيقة قيمة مناسبة. ";
$string['configproxyhost'] = "إذا كان <B>المزود</B> بحاجة إلى استخدام كمبيوتر proxy (مثل نظام firewall) للدخول على الإنترنت، فعليك بكتابة اسم مضيف proxy والمنفذ هنا. وإلا فدع المكان خاليا.";
$string['configslasharguments'] = "يتم تزويد الملفات (الصور والتحميلات، الخ) عن طريق نص يستخدم ' وسائط الفاصلة ' المائلة 'slash arguments' (وتمثل الخيار الثاني هنا). هذا الأسلوب يسمح بتخزين مؤقت للملفات في عارض الإنترنت بشكل أسهل، وكذا مزودات proxy ، إلخ. لكن للأسف بعض مزودات PHP لا تسمح بهذا الأسلوب. لذا ففي حالة نشوء مشكلة عند عرض الملفات أو الصور المحملة (مثل صور المستخدم) ينصح بوضع هذا المتغير في الخيار الأول.";
$string['configsmtphosts'] = "اكتب الاسم كاملا لمزود أو مزودات SMTP المحلية التي سوف تستخدمها Moodle في إرسال البريد (مثل 'mail.a.com' or 'mail.a.com;mail.b.com' ). إذا تركته خاليا، سوف يستخدم Moodle الأسلوب الافتراضي في إرسال البريد.";
$string['configunzip'] = "عين موضع برنامج unzip الذي تستخدمه (معUnix فقط). هذا البرنامج ضروري لفك الأرشيفات المضغوطة على المزود.";
$string['configvariables'] = "قم بتكوين المتغيرات";
$string['configzip'] = "عين موضع برنامج unzip الذي تستخدمه (معUnix فقط). هذا البرنامج ضروري لفك الأرشيفات المضغوطة على المزود.";
$string['confirmed'] = "تم تأكيد التسجيل";
$string['courseupdates'] = "تحديثات الحلقات الدراسية";
$string['cookiesenabled'] = "ينبغي أن تكون Cookies متاحة على هذا العارض";
$string['complete'] = "أكمل";
$string['copyrightnotice'] = "ملحوظة حقوق الطبع";
$string['continue'] = "استمر";
$string['country'] = "البلد";
$string['course'] = "منهج دراسي";
$string['courseformats'] = "تنسيق المنهج الدراسي";
$string['courses'] = "المناهج الدراسية";
$string['createaccount'] = "إنشاء اشتراكي الجديد";
$string['createuserandpass'] = "إنشاء اسم مستخدم جديد وكلمة مرور للدخول بهما";
$string['createziparchive'] = "إنشاء أرشيف مضغوط";
$string['currentlanguage'] = "اللغة الحالية";
$string['currentlocaltime'] = "التوقيت المحلي الحالي";
$string['databasechecking'] = "تحديث قاعدة بيانات Moodle من نسخة \$a->oldversion إلى \$a->newversion...";
$string['databasesetup'] = "تنصيب قاعدة البيانات";
$string['databasesuccess'] = "تم تحديث قاعدة البيانات بنجاح";
$string['databaseupgrades'] = "تحديث قاعدة البيانات";
$string['defaultcoursefullname'] = "الاسم الكامل للمنهج الدراسي 1";
$string['defaultcourseshortname'] = "منهج 1";
$string['defaultcoursestudent'] = "طالب";
$string['defaultcoursestudents'] = "طلاب";
$string['defaultcoursesummary'] = "اكتب فقرة مختصرة شيقة تشرح فيها موضوع المنهج الدراسي";
$string['defaultcourseteacher'] = "مدرس";
$string['defaultcourseteachers'] = "مدرسون";
$string['delete'] = "حذف";
$string['deletecheck'] = "حذف \$a ?";
$string['deletecheckfull'] = "هل أنت متأكد تماما أنك تريد حذف \$a بالكلية?";
$string['deletecompletely'] = "حذف كامل";
$string['deletecoursecheck'] = "هل أنت متأكد تماما أنك تريد حذف هذا المنهج الدراسي بالكلية بكل ما تحتويه من بيانات؟";
$string['deletecourse'] = "حذف منهج دراسي";
$string['deleted'] = "تم الحذف";
$string['deletedactivity'] = "تم الحذف \$a";
$string['deletedcourse'] = "\$a تم حذفه بالكامل";
$string['deletednot'] = "تعذر الحذف \$a !";
$string['deletingcourse'] = "حذف \$a";
$string['description'] = "الوصف";
$string['doyouagree'] = "هل قمت بقراءة هذه الشروط واستيعابها؟";
$string['edit'] = "تحرير \$a";
$string['editcoursesettings'] = "تحرير إعدادات المنهج الدراسي";
$string['editinga'] = "تحرير \$a";
$string['editmyprofile'] = "تحرير ملف البيانات";
$string['editsummary'] = "تحرير ملخص";
$string['editthisactivity'] = "تحرير هذا النشاط";
$string['edituser'] = "تحرير اشتراك المستخدم";
$string['email'] = "عنوان البريد الإلكتروني";
$string['emailformat'] = "تنسيق البريد";
$string['emailconfirm'] = "قم بتأكيد اشتراكك";
$string['emailconfirmsent'] = "
<P>يفترض إتمام إرسال بريد إلى <B>\$a</B>
<P>والذي يحتوي على إرشادات سهلة تعينك على إتمام التسجيل
<P>إذا استمرت المشاكل اتصل بمدير هذا الموقع";
$string['emailconfirmation'] = "مرحبا \$a->الاسم الأول,
تم طلب اشتراك جديد في '\$a->sitename'
باستخدام عنوانك البريدي.
لتأكيد اشتراكك الجديد يرجى الانتقال إلى عنوان الإنترنت التالي:
\$a->link
في أغلب برامج البريد يظهر ذلك في شكل رابطة زرقاء، وما عليك إلا الضغط عليها. فإذا لم يعمل ذلك، قم بقص العنوان ولصقه في خانة العنوان أعلى عارض الإنترنت.
تحيات من '\$a->sitename' المدير,
\$a->admin";
$string['emaildisplay'] = "عرض البريد";
$string['emaildisplayno'] = "إخفاء عنواني البريدي عن الكل";
$string['emaildisplayyes'] = "إظهار عنواني البريدي للكل";
$string['emaildisplaycourse'] = "إظهار عنواني البريدي للأعضاء المشاركين في حلقات دراسية أخرى فقط";
$string['emailexists'] = "هذا العنوان البريدي مسجل بالفعل.";
$string['emailmustbereal'] = "ملحوظة: لابد أن يكون عنوانك البريدي حقيقيا.";
$string['enrolmentkey'] = "مفتاح التسجيل";
$string['enrolmentkeyfrom'] = "هذا المنهج الدراسي يتطلب 'مفتاح تسجيل' - في المرة الأولى فقط<BR>
كلمة المرور التي يفترض حصولك عليها من \$a";
$string['enrolmentkeyhint'] = "مفتاح التسجيل غير صحيح. يرجى إعادة المحاولة<BR>
(هذا تلميح - إنه يبدأ بـ '\$a'";
$string['entercourse'] = "اضغط للدخول إلى هذا المنهج الدراسي";
$string['enteremailaddress'] = "أدخل عنوانك البريدي لإعادة ضبط كلمة المرور وإرسال كلمة المرور الجديدة إليك عبر البريد";
$string['existingteachers'] = "المدرسون الموجودون";
$string['error'] = "خطأ";
$string['feedback'] = "تقرير";
$string['filemissing'] = "\$a مفقود";
$string['files'] = "ملفات";
$string['filloutallfields'] = "يرجى ملء كل الخانات في هذا النموذج";
$string['firstname'] = "الاسم الأول";
$string['firsttime'] = "هل هذه هي المرة الأولى لك هنا؟";
$string['followingoptional'] = "البنود التالية اختيارية";
$string['followingrequired'] = "البنود التالية مطلوبة";
$string['forgotten'] = "هل نسيت اسم الدخول أو كلمة المرور؟";
$string['format'] = "تنسيق";
$string['formatsocial'] = "تنسيق اجتماعي";
$string['formattopics'] = "تنسيق موضوعات";
$string['formatweeks'] = "تنسيق أسبوعي";
$string['frontpagedescription'] = "وصف الصفحة الأولى";
$string['frontpageformat'] = "تنسيق الصفحة الأولى";
$string['fulllistofcourses'] = "كل الحلقات الدراسية";
$string['fullprofile'] = "ملف البيانات كامل";
$string['fullname'] = "الاسم كاملا";
$string['fullsitename'] = "اسم الموقع كاملا";
$string['gd1'] = "GD 1.x تم تنصيبه";
$string['gd2'] = "GD 2.x تم تنصيبه";
$string['gdnot'] = "لم يتم تنصيب GD";
$string['gpl'] = "حقوق الطبع (C) 2001-2002 Martin Dougiamas (http://dougiamas.com)
هذا البرنامج مجاني، يمكنك إعادة توزيعه و/أو تعديله طبقا لشروط رخصة الجمهور العامة GNU General Public License التي أصدرتها مؤسسة البرامج المجانية Free Software Foundation سواء النسخة رقم 2 أو أي نسخة أخرى تالية تختارها.
يتم توزيع هذا البرنامج رجاء الإفادة، ولا يعد هذا ضمانا ولو ضمنيا على ملائمة هذا البرنامج للتسويق أو لغرض معين. لمريد من المعلومات، راجع رخصة الجمهور العامة GNU General Public License:
http://www.gnu.org/copyleft/gpl.html";
$string['grade'] = "الصف";
$string['guestskey'] = "السماح للضيوف الذين لديهم المفتاح";
$string['guestsno'] = "لا يسمح بدخول الضيوف";
$string['guestsnotallowed'] = "عفوا '\$a' غير مسموح للضيوف بالدخول";
$string['guestsyes'] = "السماح للضيوف بدون المفتاح";
$string['guestuser'] = "مستخدم ضيف";
$string['guestuserinfo'] = "هذا المستخدم مستخدم خاص يسمح بالوصول إلى بعض حلقات الدراسة بغرض القراءة فقط.";
$string['help'] = "مساعدة";
$string['helphtml'] = "كيف تكتب html";
$string['helppicture'] = "كيفية تحميل صورة";
$string['helptext'] = "كيفية كتابة نص";
$string['helpquestions'] = "كيفية طرح أسئلة";
$string['hide'] = "إخفاء";
$string['home'] = "الصفحة الرئيسية";
$string['htmlformat'] = "Pretty HTML تنسيق";
$string['icqnumber'] = "ICQ رقم";
$string['idnumber'] = "رقم بطاقة التعريف";
$string['leavetokeep'] = "اترك المكان خاليا للاحتفاظ بكلمة المرور الحالية";
$string['invalidlogin'] = "دخول غير صحيح، يرجى إعادة المحاولة.";
$string['invalidemail'] = "عنوان البريد غير صحيح";
$string['languagegood'] = "هذه الحزمة من اللغات حديثة :-)";
$string['lastaccess'] = "آخر اتصال";
$string['lastedited'] = "آخر تحرير";
$string['lastmodified'] = "آخر تعديل";
$string['lastname'] = "الاسم الأخير";
$string['latestnews'] = "آخر الأخبار";
$string['listofallpeople'] = "قائمة بجميع الأشخاص";
$string['license'] = "GPL رخصة";
$string['livelogs'] = "ملفات سجلات حية عن الساعة الأخيرة";
$string['locale'] = "ar";
$string['location'] = "الموقع";
$string['loggedinas'] = "تم دخولك بصفة \$a.";
$string['loggedinnot'] = "لم يتم دخولك.";
$string['login'] = "دخول";
$string['loginas'] = "دخول بصفة";
$string['loginguest'] = "الدخول بصفة ضيف";
$string['loginsite'] = "دخول إلى الموقع";
$string['loginto'] = "دخول إلى\$a";
$string['loginusing'] = "ادخل هنا مستخدما اسم المستخدم وكلمة المرور";
$string['loginsteps'] = "مرحبا! للاتصال الكامل بالحلقات الدراسية سوف يستغرق الأمر لحظات لإنشاء اشتراك جديد على هذا الموقع. كل من الحلقات الدراسية المنفردة قد يكون له أيضا &quot;مفتاح تسجيل&quot; والذي لن تحتاج إليه إلا لاحقا. وهذه هي الخطوات:
<OL size=2>
<LI>املأ نموذج <A HREF=\$a>New Account</A> مستخدما بياناتك.
<LI>على الفور توجه رسالة إلى عنوانك البريدي.
<LI>قم بقراءة البريد واضغط على الرابطة الموجودة به.
<LI>سيتم تأكيد اشتراكك ويسمح لك بالدخول.
<LI>والآن قم باختيار المنهج الدراسي الذي ترغب المشاركة فيه.
<LI>والآن تستطيع الاتصال الكامل بالمنهج الدراسي. من الآن فصاعدا لن تحتاج إلا إلى إدخال اسم المستخدم وكلمة المرور (في النموذج الموجود بهذه الصفحة) حتى يتم الدخول وتصل إلى أي المنهج دراسي تريد التسجيل بها.
<LI>إذا طلب منك ''مفتاح التسجيل'' - استخدم المفتاح الذي أعطاه لك المدرس. هذا سيجعلك ''تسجل'' في المنهج الدراسي.
</OL>";
$string['loginstepsnone'] = "مرحبا!<P>للاتصال الكامل بالحلقات الدراسية ستحتاج إلى إنشاء اشتراك جديد.<P>كل ما عليك هو عمل اسم مستخدم وكلمة مرور واستخدامهما في النموذج الموجود بهذه الصفحة!<P>إذا كان اسم المستخدم قد تم استخدامه من قبل، جرب مرة أخرى مستخدما اسما آخر.";
$string['logout'] = "خروج";
$string['logs'] = "سجلات";
$string['makeafolder'] = "إنشاء مجلد";
$string['makeeditable'] = "إذا جعلت '\$a' قابلا للتحرير من خلال عملية مزود الإنترنت (مثال apache) ثم تستطيع تحرير هذا الملف مباشرة من خلال هذه الصفحة";
$string['mainmenu'] = "القائمة الرئيسية";
$string['managedatabase'] = "إدارة قاعدة البيانات";
$string['markthistopic'] = "ميز هذا الموضوع بعلامة كالموضوع الحالي";
$string['maximumchars'] = "الحد الأقصى \$a من الحروف";
$string['maximumgrade'] = "أعلى مرحلة";
$string['maxsize'] = "الحد الأقصى \$a";
$string['miscellaneous'] = "متنوع"; // Default course category
$string['missingcategory'] = "لابد من اختيار فئة";
$string['missingcity'] = "المدينة/البلد مفقودة";
$string['missingcountry'] = "البلد مفقودة";
$string['missingdescription'] = "الوصف مفقود";
$string['missingemail'] = "العنوان البريدي مفقود";
$string['missingfirstname'] = "الاسم الأول مفقود";
$string['missingfullname'] = "الاسم كاملا مفقود";
$string['missinglastname'] = "الاسم الأخير مفقود";
$string['missingshortname'] = "الاسم المختصر مفقود";
$string['missingnewpassword'] = "كلمة المرور الجديدة مفقودة";
$string['missingpassword'] = "كلمة المرور مفقودة";
$string['missingshortsitename'] = "اسم الموقع المختصر مفقود";
$string['missingsitedescription'] = "وصف الموقع مفقود";
$string['missingsitename'] = "اسم الموقع مفقود";
$string['missingstrings'] = "ابحث عن سلسلة الأحرف المفقودة";
$string['missingstudent'] = "لابد من اختيار شيء";
$string['missingsummary'] = "الملخص مفقود";
$string['missingteacher'] = "لابد من اختيار شيء";
$string['missingusername'] = "اسم المستخدم مفقود";
$string['modified'] = "تم التعديل";
$string['modulesetup'] = "تنصيب جداول الوحدة النمطية";
$string['modulesuccess'] = "\$a تم تنصيب الجداول بشكل صحيح";
$string['mostrecently'] = "الأحدث";
$string['movedown'] = "الانتقال إلى أسفل";
$string['moveup'] = "الانتقال إلى أعلى";
$string['movetoanotherfolder'] = "نقل إلى مجلد آخر";
$string['movefilestohere'] = "أنقل الملفات إلى هنا";
$string['mustconfirm'] = "أنت تحتاج إلى تأكيد الدخول";
$string['mycourses'] = "حلقاتي الدراسية";
$string['name'] = "الاسم";
$string['namesocial'] = "القسم";
$string['nametopics'] = "الموضوع";
$string['nameweeks'] = "الأسبوع";
$string['newaccount'] = "اشتراك جديد";
$string['newpassword'] = "كلمة مرور جديدة";
$string['newpasswordtext'] = "مرحبا \$a->firstname,
كلمة المرور الخاصة باشتراكك على قد تم إعادة ضبطها وتم تخصيص كلمة مرور جديدة مؤقتة خاصة بك
معلومات الدخول الحالية الخاصة بك الآن:
اسم المستخدم: \$a->username
كلمة المرور: \$a->newpassword
يرجى الانتقال إلى هذه الصفحة لتغيير كلمة المرور:
\$a->link
في أغلب برامج البريد يظهر ذلك في شكل رابطة زرقاء، وما عليك إلا الضغط عليها. فإذا لم يعمل ذلك، قم بقص العنوان ولصقه في خانة العنوان أعلى عارض الإنترنت.
تحيات من '\$a->sitename' المدير,
\$a->signoff\n";
$string['newpicture'] = "صورة جديدة";
$string['newuser'] = "مستخدم جديد";
$string['newusers'] = "مستخدمون جدد";
$string['newsitem'] = "بند أخبار";
$string['newsitems'] = "بنود أخبار";
$string['newsitemsnumber'] = "بنود أخبار للعرض";
$string['never'] = "أبدا";
$string['no'] = "لا";
$string['nocoursesyet'] = "لا توجد حلقات دراسية لهذه الفئة";
$string['noexistingteachers'] = "لا يوجد مدرسون حضور";
$string['nograde'] = "لا يوجد مرحلة";
$string['none'] = "لا يوجد";
$string['nopotentialteachers'] = "لا يوجد مدرس محتمل";
$string['normal'] = "عادي";
$string['nostudentsyet'] = "لم يتم تسجيل أي طلاب في هذا المنهج الدراسي بعد";
$string['nosuchemail'] = "لا يوجد مثل هذا العنوان البريدي";
$string['noteachersyet'] = "لا يوجد مدرسون في هذا المنهج الدراسي بعد";
$string['notenrolled'] = "\$a غير مسجل في هذا المنهج الدراسي";
$string['nothingnew'] = "لم يستجد شيء منذ آخر دخول قمت به";
$string['nousersyet'] = "ليس هناك مستخدمون حتى الآن";
$string['now'] = "الآن";
$string['numberweeks'] = "عدد الأسابيع/المواضيع";
$string['numdays'] = "\$a يوما";
$string['numminutes'] = "\$a دقيقة";
$string['numviews'] = "\$a آراء";
$string['numweeks'] = "\$a أسابيع";
$string['numwords'] = "\$a كلمات";
$string['numyears'] = "\$a أعوام";
$string['ok'] = "OK";
$string['opentoguests'] = "اتصال الضيف";
$string['optional'] = "اختياري";
$string['order'] = "طلب";
$string['outline'] = "ملخص";
$string['participants'] = "المشاركات";
$string['password'] = "كلمة المرور";
$string['passwordchanged'] = "تم تغيير كلمة المرور";
$string['passwordsdiffer'] = "كلمات المرور لا تتطابق";
$string['passwordsent'] = "تم إرسال كلمة المرور";
$string['passwordsenttext'] = "
<P>تم إرسال رسالة إلى العنوان \$a->البريد.
<P><B>يرجى البحث في البريد عن كلمة المرور</B>
<P>تم إصدار كلمة مرور جديدة، وربما رغبت في
<A HREF=\$a->link>في تغييرها إلى شيء أبسط من ذلك حتى يسهل تذكرها</A>.";
$string['people'] = "أشخاص";
$string['personalprofile'] = "ملف البيانات شخصي";
$string['phone'] = "تليفون";
$string['potentialteachers'] = "مدرسون محتملون";
$string['preferredlanguage'] = "اللغة المفضلة";
$string['preview'] = "معاينة";
$string['previeworchoose'] = "عاين موضوع أو قم باختياره";
$string['question'] = "سؤال";
$string['readme'] = "ملف الملاحظات"; // This is a file name
$string['recentactivity'] = "الأنشطة الحديثة";
$string['removeteacher'] = "إزالة مدرس";
$string['rename'] = "Rename";
$string['resources'] = "المصادر";
$string['returningtosite'] = "هل تريد الرجوع إلى هذا الموقع؟";
$string['requireskey'] = "هذا المنهج الدراسي بحاجة إلى مفتاح التسجيل";
$string['revert'] = "عكس";
$string['role'] = "الدور";
$string['savechanges'] = "حفظ التغييرات";
$string['search'] = "بحث";
$string['searchagain'] = "بحث مرة أخرى";
$string['searchresults'] = "نتائج البحث";
$string['section'] = "قسم";
$string['selectacountry'] = "اختر دولة";
$string['senddetails'] = "أرسل بياناتي بالبريد";
$string['separateandconnected'] = "طرق متفرقة ومتصلة للمعرفة";
$string['serverlocaltime'] = "التوقيت المحلي للمزود";
$string['settings'] = "الإعدادات";
$string['shortname'] = "الاسم المختصر";
$string['shortsitename'] = "اسم الموقع المختصر (كلمة واحدة على سبيل المثال)";
$string['showalltopics'] = "إظهار كل الموضوعات";
$string['showallweeks'] = "إظهار كل الأسابيع";
$string['showlistofcourses'] = "إظهار قائمة الحلقات الدراسية";
$string['showonlytopic'] = "فقط إظهار موضوع \$a";
$string['showonlyweek'] = "فقط إظهار أسبوع \$a";
$string['showtheselogs'] = "إظهار ملفات السجلات هذه";
$string['socialheadline'] = "المنتدى الاجتماعي - آخر الموضوعات";
$string['showallcourses'] = "إظهار كل الحلقات الدراسية";
$string['site'] = "الموقع";
$string['sites'] = "المواقع";
$string['sitelogs'] = "ملفات سجلات الموقع";
$string['sitenews'] = "أخبار الموقع";
$string['sitesettings'] = "إعدادات الموقع";
$string['size'] = "الحجم";
$string['someallowguest'] = "بعض حلقات الدراسة تسمح بوجود المستخدمين الضيوف";
$string['startdate'] = "تاريخ بدء المنهج الدراسي";
$string['startsignup'] = "ابدأ الآن بإنشاء اشتراك جديد!";
$string['status'] = "الحالة";
$string['stringsnotset'] = "لم يتم تعريف الإعدادات التالية في \$a";
$string['success'] = "نجاح";
$string['summary'] = "ملخص";
$string['summaryof'] = "ملخص لـ \$a";
$string['supplyinfo'] = "يرجى إعطاء بعض المعلومات عنك";
$string['teacheronly'] = "فقط من أجل \$a ";
$string['textformat'] = "تنسيق نص عادي";
$string['timezone'] = "المنطقة الزمنية";
$string['thanks'] = "شكرا";
$string['theme'] = "الموضوع";
$string['themesaved'] = "تم حفظ موضوع جديد";
$string['today'] = "اليوم";
$string['todaylogs'] = "ملفات سجلات اليوم";
$string['toomanytoshow'] = "عدد المستخدمين يفوق قدرات العرض";
$string['topic'] = "موضوع";
$string['topicoutline'] = "مخطط أيجازي للموضوع";
$string['turneditingoff'] = "إيقاف التحرير";
$string['turneditingon'] = "تشغيل التحرير";
$string['undecided'] = "غير محدد";
$string['unenrol'] = "إلغاء التسجيل";
$string['unenrolme'] = "إلغاء تسجيلي من \$a";
$string['unenrolsure'] = "هل أنت متأكد أنك تريد إلغاء التسجيل \$a من هذا المنهج الدراسي?";
$string['unsafepassword'] = "كلمة مرور غير آمنة - جرب أخرى";
$string['unzip'] = "فك";
$string['update'] = "تحديث";
$string['updated'] = "تم تحديث \$a";
$string['updatemyprofile'] = "تحديث الملف الوصفي";
$string['updatesevery'] = "يتم التحديث كل \$a seconds";
$string['updatethiscourse'] = "تحديث هذا المنهج الدراسي";
$string['updatinga'] = "تحديث \$a";
$string['updatingain'] = "تحديث \$a->what in \$a->in";
$string['upload'] = "تحميل";
$string['uploadafile'] = "تحميل ملف";
$string['uploadthisfile'] = "تحميل هذا الملف";
$string['userdeleted'] = "تم حذف اشتراك هذا المستخدم";
$string['userdescription'] = "الوصف";
$string['username'] = "اسم المستخدم";
$string['usernameexists'] = "اسم المستخدم موجود بالفعل، اختر اسما آخر";
$string['userprofilefor'] = "ملف المستخدم التعريفي for \$a";
$string['users'] = "المستخدمون";
$string['webpage'] = "صفحة إنترنت";
$string['week'] = "أسبوع";
$string['weeklyoutline'] = "ملخص أسبوعي";
$string['welcometocourse'] = "مرحبا في \$a";
$string['welcometocoursetext'] = "مرحبا في \$a->coursename!
من الأشياء التي يجب أن تفعلها ابتداء أن تقوم بتحرير الصفحة التعريفية خلال المنهج الدراسي حتى نعرف المزيد عنك
\$a->profileurl";
$string['withchosenfiles'] = "مع الملفات المختارة";
$string['wordforteacher'] = "كلمة توجهها إلى المدرس";
$string['wordforteachereg'] = "مثلا: المدرس، المعلم، معاون تسهيل الإجراءات";
$string['wordforteachers'] = "كلمة توجهها إلى المدرسين";
$string['wordforteacherseg'] = "مثلا: المدرسين، المعلمين، معاني تسهيل الإجراءات";
$string['wordforstudent'] = "كلمة توجهها إلى طالب";
$string['wordforstudenteg'] = "مثلا: طالب، مشترك، إلخ";
$string['wordforstudents'] = "كلمة توجهها إلى الطلاب";
$string['wordforstudentseg'] = "مثلا: الطلاب، المشاركون، إلخ";
$string['wrongpassword'] = "كلمة المرور غير صحيحة بالنسبة لاسم المستخدم";
$string['yes'] = "نعم";
$string['yourlastlogin'] = "آخر دخول لك كان";
$string['yourself'] = "أنت نفسك";
$string['yourteacher'] = "صلته بك \$a";
$string['allownot'] = "لا تسمح";
$string['assessment'] = "تقييم";
$string['closewindow'] = "أغلق هذه النافذة";
$string['confightmleditor'] = "اختر ما إذا كنت تسمح باستخدام محرر نصوص HTML. عندما تختار اسمح فإن هذا المحرر سوف يظهر فقط عندما يتم استخدام متصفح موائم (مثل IE 5.5 أو أعلى). ويمكن للمستخدم ألا يختار استخدام المحرر.";
$string['configlangdir'] = "يتم طباعة معظم اللغات من الشمال إلى اليمين، ولكن بعض اللغات مثل العربي والعبري يتم الطباعة من اليمن إلى الشمال.";
$string['day'] = "يوم";
$string['days'] = "أيام";
$string['downloadexcel'] = "تحميل في صيغة Excel";
$string['downloadtext'] = "تحميل في صيغة نص";
$string['formathtml'] = "صيغة HTML";
$string['formattext'] = "صيغة تلقائية";
$string['formattexttype'] = "تنسيق";
$string['grades'] = "درجات";
$string['helprichtext'] = "معلومات عن محرر Richtext HTML";
$string['hour'] = "ساعة";
$string['hours'] = "ساعات";
$string['htmleditor'] = "استخدم محرر Richtext HTML (متصفح IE 5.5 أو أعلى)";
$string['htmleditoravailable'] = "محرر Richtext متاح";
$string['htmleditordisabled'] = "لقد قمت بإلغاء محرر Richtext في خيارات المستخدم";
$string['htmleditordisabledadmin'] = "قام مدير الموقع بإلغاء محرر Richtext على الموقع";
$string['htmleditordisabledbrowser'] = "محرر Richtext غير متاح لأنك لا تستخدم IE 5.5 أو أعلى";
$string['langltr'] = "اتجاه اللغة من الشمال إلى اليمين";
$string['langrtl'] = "اتجاه اللغة من اليمين إلى الشمال";
$string['maximumshort'] = "الحد الأقصى";
$string['min'] = "الحد الأدنى";
$string['mins'] = "mins";
$string['new'] = "جديد";
$string['nofilesyet'] = "لم يتم تحميل أي ملف للمنهج الخاص بك بعد";
$string['noimagesyet'] = "لم يتم تحميل أي صورة للمنهج الخاص بك بعد";
$string['sec'] = "ثانية";
$string['secs'] = "ثواني";
$string['textediting'] = "عند تحرير النصوص";
$string['texteditor'] = "استخدم نماذج الإنترنت القياسية";
$string['total'] = "مجموع";
$string['updatethis'] = "طور هذا \$a";
$string['allow'] = "اسمح";
?>
+103
View File
@@ -0,0 +1,103 @@
<?PHP // $Id$
#------------------------------------------------------------
$string['modulename'] = "ÇãÊÍÇä";
$string['modulenameplural'] = "ÇãÊÍÇäÇÊ";
#------------------------------------------------------------
$string['addselectedtoquiz'] = "Add selected to quiz";
$string['alwaysavailable'] = "Always available";
$string['alreadysubmitted'] = "It is likely that you have already submitted this attempt";
$string['answer'] = "Answer";
$string['answerhowmany'] = "One or multiple answers?";
$string['answersingleyes'] = "One answer only";
$string['answersingleno'] = "Multiple answers allowed";
$string['attempt'] = "Attempt \$a";
$string['attemptfirst'] = "First attempt";
$string['attemptlast'] = "Last attempt";
$string['attemptquiznow'] = "Attempt quiz now";
$string['attempts'] = "Attempts";
$string['attemptsallowed'] = "Attempts allowed";
$string['attemptsunlimited'] = "Unlimited attempts";
$string['backtoquiz'] = "Back to quiz editing";
$string['bestgrade'] = "Best grade";
$string['casesensitive'] = "Case sensitivity";
$string['caseyes'] = "Yes, case must match";
$string['caseno'] = "No, case is unimportant";
$string['categories'] = "Categories";
$string['category'] = "Category";
$string['categoryinfo'] = "Category info";
$string['categorymove'] = "The category '\$a->name' contains \$a->count questions. Please choose another category to move them to.";
$string['categorymoveto'] = "Move them to this category";
$string['choice'] = "Choice";
$string['choices'] = "Available choices";
$string['correctanswer'] = "Correct answer";
$string['correctanswers'] = "Correct answers";
$string['createnewquestion'] = "Create new question";
$string['daysavailable'] = "Days available";
$string['default'] = "Default";
$string['defaultinfo'] = "The default category for questions.";
$string['deletequestioncheck'] = "Are you absolutely sure you want to delete '\$a'?";
$string['editcategories'] = "Edit categories";
$string['editingquiz'] = "Editing quiz";
$string['editingquestion'] = "Editing a question";
$string['editingshortanswer'] = "Editing a short answer question";
$string['editingtruefalse'] = "Editing a true/false question";
$string['editingmultichoice'] = "Editing a multiple choice question";
$string['false'] = "False";
$string['feedback'] = "Feedback";
$string['filloutoneanswer'] = "You must fill out at least one possible answer. Answers left blank will not be used.";
$string['fillouttwochoices'] = "You must fill out at least two choices. Choices left blank will not be used.";
$string['fractionsaddwrong'] = "The positive grades you have chosen do not add up to 100%%
<BR>Instead, they add up to \$a%%
<BR>Do you want to go back and fix this question?";
$string['fractionsnomax'] = "One of the answers should be 100%%, so that it is
<BR>possible to get a full grade for this question.
<BR>Do you want to go back and fix this question?";
$string['gradeaverage'] = "Average grade";
$string['gradehighest'] = "Highest grade";
$string['grademethod'] = "Grading method";
$string['guestsno'] = "Sorry, guests can not see or attempt quizzes";
$string['imagedisplay'] = "Image to display";
$string['introduction'] = "Introduction";
$string['marks'] = "Marks";
$string['multichoice'] = "Multiple Choice";
$string['noanswers'] = "No answers were selected!";
$string['noattempts'] = "No attempts have been made on this quiz";
$string['nomoreattempts'] = "No more attempts are allowed";
$string['noquestions'] = "No questions have been added yet";
$string['publish'] = "Publish";
$string['question'] = "Question";
$string['questioninuse'] = "The question '\$a' is currently being used:";
$string['questions'] = "Questions";
$string['questionname'] = "Question name";
$string['quizavailable'] = "The quiz is available until: \$a";
$string['quizclose'] = "Close the quiz";
$string['quizclosed'] = "This quiz closed on \$a";
$string['quizopen'] = "Open the quiz";
$string['quiznotavailable'] = "The quiz will not be available until: \$a";
$string['random'] = "Random set";
$string['regrade'] = "Regrade all attempts";
$string['regradecomplete'] = "All attempts have been regraded";
$string['regradecount'] = "\$a->changed out of \$a->attempt grades were changed";
$string['rename'] = "Rename";
$string['report'] = "Reports";
$string['save'] = "Save";
$string['savegrades'] = "Save grades";
$string['savemyanswers'] = "Save my answers";
$string['savequiz'] = "Save this whole quiz";
$string['score'] = "Raw score";
$string['select'] = "Select";
$string['selectcategoryabove'] = "Select a category above";
$string['shortanswer'] = "Short Answer";
$string['show'] = "Show";
$string['showfeedback'] = "After answering, show feedback?";
$string['showcorrectanswer'] = "In feedback, show correct answers?";
$string['time'] = "Time";
$string['timetaken'] = "Time taken";
$string['timecompleted'] = "Completed";
$string['true'] = "True";
$string['truefalse'] = "True/False";
$string['type'] = "Type";
$string['viewallanswers'] = "View \$a completed quizzes";
$string['yourfinalgradeis'] = "Your final grade for this quiz is \$a";
+29
View File
@@ -0,0 +1,29 @@
<?PHP // $Id$
#------------------------------------------------------------
$string['modulename'] = "ãÕÏÑ";
$string['modulenameplural'] = "ãÕÇÏÑ";
#------------------------------------------------------------
$string['addresource'] = "Add resource";
$string['editingaresource'] = "Editing a resource";
$string['example'] = "Example";
$string['examplereference'] = "Tobin, K. & Tippins, D (1993) Constructivism as a Referent for Teaching and Learning. In: K. Tobin (Ed) The Practice of Constructivism in Science Education, pp 3-21, Lawrence-Erlbaum, Hillsdale, NJ.";
$string['exampleurl'] = "http://www.example.com/somedirectory/somefile.html";
$string['filename'] = "File name";
$string['fulltext'] = "Full text";
$string['htmlfragment'] = "HTML fragment";
$string['neverseen'] = "Never seen";
$string['note'] = "Note";
$string['notefile'] = "To upload more files into the course (so they appear in this list) use the
<A HREF=\$a >File Manager</A>.";
$string['notypechosen'] = "You need to choose a type. Use your back button to go back and retry.";
$string['resourcetype'] = "Type of resource";
$string['resourcetype1'] = "Reference";
$string['resourcetype2'] = "Web Page";
$string['resourcetype3'] = "Uploaded File";
$string['resourcetype4'] = "Plain text";
$string['resourcetype5'] = "Web Link";
$string['resourcetype6'] = "HTML text";
?>
+46
View File
@@ -0,0 +1,46 @@
<?PHP // $Id$
#------------------------------------------------------------
$string['modulename'] = "ÇáÍÕÉ ÇáÏÑÇÓíå";
$string['modulenameplural'] = "ÃÎÊíÇÑÇÊ";
#------------------------------------------------------------
$string['actual'] = "Actual";
$string['allquestions'] = "All questions in order, all students";
$string['allscales'] = "All scales, all students";
$string['alreadysubmitted'] = "You have already submitted this survey";
$string['analysisof'] = "Analysis of \$a";
$string['ipreferthat'] = "I prefer that";
$string['ifoundthat'] = "I found that";
$string['done'] = "Done";
$string['download'] = "Download";
$string['downloadexcel'] = "Download data as Excel spreadsheet";
$string['downloadinfo'] = "You can download the complete raw data for this survey in a form suitable for analysis in Excel, SPSS or other package.";
$string['downloadtext'] = "Download data as a plain text file";
$string['editingasurvey'] = "Editing a survey";
$string['helpsurveys'] = "Help on the different types of surveys";
$string['introtext'] = "Introduction text";
$string['name'] = "Name";
$string['newsurveyresponses'] = "New survey responses";
$string['nobodyyet'] = "Nobody has yet completed this survey";
$string['notdone'] = "Not done yet";
$string['notes'] = "Your private analysis and notes";
$string['peoplecompleted'] = "\$a people have completed this survey so far";
$string['preferred'] = "Preferred";
$string['questions'] = "Questions";
$string['question'] = "Question";
$string['report'] = "Survey report";
$string['scales'] = "Scales";
$string['savednotes'] = "Your notes were saved";
$string['seemoredetail'] = "Click here to see more detail";
$string['selectedquestions'] = "Selected questions from a scale, all students";
$string['summary'] = "Summary";
$string['surveycompleted'] = "You've completed this survey. The graph below shows a summary of your results compared to the class averages.";
$string['surveyname'] = "Survey name";
$string['surveysaved'] = "Survey saved";
$string['surveytype'] = "Survey type";
$string['thanksforanswers'] = "Thanks for answering this survey, \$a";
$string['time'] = "Time";
$string['viewsurveyresponses'] = "View \$a survey responses";
?>
Executable
+19
View File
@@ -0,0 +1,19 @@
README FOR CATALAN PLUGIN
-------------------------
Translation by Carles Bellver (with the help of Mercè Renau,
Clara Andrés and Jordi Adell).
Missing strings:
- almost all survey.php
- a lot of help files :-(
Centre d'Educació i Noves Tecnologies
Universitat Jaume I
12071 Castelló de la Plana
Spain
mailto:cent@uji.es
http://cent.uji.es
+42
View File
@@ -0,0 +1,42 @@
<?PHP // $Id$
// assignment.php - created with Moodle 1.0.5 beta 1 (2002092500)
$string['assignmentdetails'] = "Detalls de la tasca";
$string['assignmentname'] = "Nom de la tasca";
$string['assignmenttype'] = "Tipus de tasca";
$string['description'] = "Descripció";
$string['duedate'] = "Data de venciment";
$string['early'] = "\$a prompte";
$string['failedupdatefeedback'] = "Ha fallat l'actualització dels comentaris sobre l'enviament de l'usuari \$a";
$string['feedbackupdated'] = "Actualització dels comentaris sobre els enviaments de \$a persones";
$string['late'] = "\$a tard";
$string['maximumgrade'] = "Nota màxima";
$string['maximumsize'] = "Mida màxima";
$string['modulename'] = "Tasca";
$string['modulenameplural'] = "Tasques";
$string['newsubmissions'] = "Tasques enviades";
$string['notsubmittedyet'] = "No enviada encara";
$string['overwritewarning'] = "Avís: si tornes a pujar el fitxer REEMPLAÇARÀS el que hi ha";
$string['submissionfeedback'] = "Comentaris sobre l'enviament";
$string['submissions'] = "Enviaments";
$string['submitted'] = "Enviada";
$string['typeuploadsingle'] = "Penjar un únic fitxer, valor entre 0 i 100";
$string['uploadedfiles'] = "fitxers penjats";
$string['viewsubmissions'] = "Veure \$a tasques enviades";
$string['yoursubmission'] = "El teu enviament";
$string[submitassignment] = "Envia la teua tasca per mitjà d'aquest formulari";
$string[typeoffline] = "Activitat offline";
$string[uploadbadname] = "El nom d'aquest fitxer conté caràcters estranys i no es pot penjar";
$string[uploaderror] = "S'ha produït un error quan s'estava guardant el fitxer en el servidor";
$string[uploadfailnoupdate] = "El fitxer s'ha penjat correctament, però no es pot actualitzar el registre de l'enviament!";
$string[uploadfiletoobig] = "Ho lamentem, el fitxer és massa gran (el límit són \$a bytes)";
$string[uploadnofilefound] = "No s'ha pogut trobar el fitxer. Segur que n'havies seleccionat un?";
$string[uploadnotregistered] = "'\$a' s'ha penjat correctament, però no es pot registrar l'enviament!";
$string[uploadsuccess] = "'\$a' penjat correctament";
$string[viewfeedback] = "Veure les qualificacions de les tasques i els comentaris";
$string[allowresubmit] = "Permetre de tornar a enviar";
?>
+17
View File
@@ -0,0 +1,17 @@
<?PHP // $Id$
// choice.php - created with Moodle 1.0.5 beta 1 (2002092500)
$string['answered'] = "Contestades";
$string['choice'] = "Opció \$a";
$string['choicename'] = "Nom de l'opció";
$string['choicetext'] = "Text de l'opció";
$string['modulename'] = "Qüestió";
$string['modulenameplural'] = "Qüestions";
$string['notanswered'] = "No contestada encara";
$string['responses'] = "Respostes";
$string['responsesto'] = "Respostes per a \$a";
$string['savemychoice'] = "Guardar la resposta";
$string['viewallresponses'] = "Veure \$a respostes";
?>
+19
View File
@@ -0,0 +1,19 @@
ABOUT THIS DIRECTORY
--------------------
DO NOT CHANGE, RENAME OR MOVE ANY OF THE FILES
IN THIS DIRECTORY unless you REALLY know what
you are doing.
Changing these files could mess up your course.
This directory contains files uploaded to your
course within particular modules (mostly by
students), such as assignment submissions and
forum attachments.
The names of the directories and files within
this directory are very specific and are
automatically maintained by Moodle.
+131
View File
@@ -0,0 +1,131 @@
<?PHP // $Id$
// forum.php - created with Moodle 1.0.5 beta 1 (2002092500)
$string['addanewdiscussion'] = "Afegir un tema de debat";
$string['allowchoice'] = "Permetre elegir a tothom";
$string['allowdiscussions'] = "Pot un \$a començar un nou debat?";
$string['allowratings'] = "Permetre valorar els missatges?";
$string['allowsdiscussions'] = "Aquest fòrum permet a cadascú començar un tema de debat.";
$string['anyfile'] = "Qualsevol fitxer";
$string['attachment'] = "Fitxer adjunt";
$string['bynameondate'] = "per \$a->name - \$a->date";
$string['canstudentsstart'] = "Pot un \$a començar un nou debat?";
$string['couldnotadd'] = "Un error desconegut ha impedit afegir el teu missatge";
$string['couldnotdeleteratings'] = "Ho lamentem, no es pot esborrar perquè ja l'han valorat altres";
$string['couldnotdeletereplies'] = "Ho lamentem, no es pot esborrar perquè ja ha tingut contestacions";
$string['couldnotupdate'] = "Un error desconegut ha impedit actualitzar el teu missatge";
$string['delete'] = "Esborrar";
$string['deleteddiscussion'] = "Tema de debat esborrat";
$string['deletedpost'] = "Missatge esborrat";
$string['deletesure'] = "Segur que vols esborrar aquest missatge?";
$string['discussion'] = "Debat";
$string['discussions'] = "Debats";
$string['discussionsstartedby'] = "Debats començats per \$a";
$string['discussthistopic'] = "Debatre aquest tema";
$string['eachuserforum'] = "Cada persona envia un debat";
$string['edit'] = "Editar";
$string['editing'] = "Editant";
$string['emptymessage'] = "El teu missatge presentava algun problema. Potser l'havies deixat en blanc, o el fitxer adjunt era massa gran. Els canvis NO s'han guardat.";
$string['everyonecanchoose'] = "Cadascú pot elegir subscriure's";
$string['everyoneissubscribed'] = "Tothom està subscrit a aquest fòrum";
$string['forcesubscribe'] = "Forçar que tothom estiga subscrit";
$string['forcesubscribeq'] = "Forçar que tothom estiga subscrit?";
$string['forum'] = "Fòrum";
$string['forumintro'] = "Introducció al fòrum";
$string['forumname'] = "Nom del fòrum";
$string['forums'] = "Fòrums";
$string['forumtype'] = "Tipus de fòrum";
$string['generalforum'] = "Fòrum estàndard per a ús general";
$string['generalforums'] = "Fòrums generals";
$string['inforum'] = "en \$a";
$string['intronews'] = "Anuncis i notícies generals";
$string['introsocial'] = "Un fòrum obert per a xarrar sobre qualsevol cosa que es vulga";
$string['introteacher'] = "Un fòrum només per a notes i debats del professorat";
$string['learningforums'] = "Fòrums per a aprendre";
$string['maxtimehaspassed'] = "Ho lamentem, ha passat el temps màxim per a editar aquest missatge! (\$a)";
$string['message'] = "Missatge";
$string['modeflatnewestfirst'] = "Mostrar llista de rèpliques començant per la més nova";
$string['modeflatoldestfirst'] = "Mostrar llista de rèpliques començant per la més antiga";
$string['modenested'] = "Mostrar rèpliques escalonades";
$string['modethreaded'] = "Mostrar rèpliques per temes";
$string['modulename'] = "Fòrum";
$string['modulenameplural'] = "Fòrums";
$string['more'] = "més";
$string['namenews'] = "Nou fòrum";
$string['namesocial'] = "Fòrum social";
$string['nameteacher'] = "Fòrum del professorat";
$string['newforumposts'] = "Nous enviaments als fòrums";
$string['nodiscussions'] = "Encara no hi ha cap tema de debat en aquest fòrum";
$string['noguestpost'] = "Ho lamentem, els usuaris invitats no poden enviar missatges";
$string['noposts'] = "No hi ha missatges";
$string['nosubscribers'] = "Encara no hi ha subscriptors en aquest fòrum";
$string['nownotsubscribed'] = "\$a->name NO rebrrà còpies de '\$a->forum' per correu electrònic.";
$string['nowsubscribed'] = "\$a->name rebrà còpies de '\$a->forum' per correu electrònic.";
$string['numposts'] = "\$a missatges";
$string['olderdiscussions'] = "Debats anteriors";
$string['parentofthispost'] = "Missatge original";
$string['postadded'] = "S'ha afegit el teu missatge.<P>Tens \$a per a editar-lo si vols fer algun canvi.";
$string['postingtip'] = "<B>Suggeriments:</B>
Quan envies una resposta:
<UL>
<LI>llegeix el missatge original amb molt de compte i practica l'empatia
<LI>busca els aspectes que pugues comentar
</UL>
Mentre escrius:
<UL>
<LI>mira que les teues respostes siguen curtes i centra't en el tema
<LI>explica les teus idees clarament
<LI>pensa preguntes que podries fer
</UL>";
$string['postmailinfo'] = "Açò és una còpia d'un missatge enviat al lloc web \$a.
Per a afegir la teua resposta via web, fes clic en aquest enllaç:";
$string['postrating1'] = "Mostra sobretot coneixements SEPARATS";
$string['postrating2'] = "Tant separats com connectats";
$string['postrating3'] = "Mostra sobretot coneixements CONNECTATS";
$string['postupdated'] = "S'ha actualitzat el teu missatge.";
$string['processingpost'] = "Processant missatge \$a";
$string['rate'] = "Valoració";
$string['ratings'] = "Valoracions";
$string['re'] = "Re:";
$string['readtherest'] = "Llegir la resta del tema";
$string['repliesmany'] = "\$a respostes fins ara";
$string['repliesone'] = "\$a resposta fins ara";
$string['reply'] = "Contestar";
$string['search'] = "Buscar";
$string['searchforums'] = "Buscar en els fòrums";
$string['sendinratings'] = "Enviar les meues últimes valoracions";
$string['showsubscribers'] = "Mostra els subscriptors";
$string['singleforum'] = "Un debat simple";
$string['subject'] = "Títol";
$string['subscribe'] = "Subscriure's a aquest fòrum";
$string['subscribed'] = "Subscrit";
$string['subscribers'] = "Subscriptors";
$string['subscribersto'] = "Subscriptors de '\$a'";
$string['unsubscribe'] = "Cancel·lar la subscripció a aquest fòrum";
$string['youratedthis'] = "La teua valoració";
$string['yournewtopic'] = "Nou tema de debat";
$string['yourreply'] = "La teua resposta";
$string[nopostscontaining] = "No s'ha trobat cap missatge que continga '\$a'";
$string[openmode0] = "Debats no, respostes no";
$string[openmode1] = "Debats no, però respostes sí";
$string[openmode2] = "Debats i respostes sí";
$string[postincontext] = "Veure aquest missatge en el seu context";
$string[searchresults] = "Resultats de la recerca";
?>
+7
View File
@@ -0,0 +1,7 @@
<P ALIGN=CENTER><B>Categories de cursos</B></P>
<P>L'administrador de Moodle pot haver establert diferents categories de cursos.</P>
<P>Per exemple: "Ci&egrave;ncies", "Humanitats", "Salut", etc.
<P>Tria la que siga m&eacute;s pertinent al teu curs. La teua elecci&oacute; condicionar&agrave; el posicionament del curs dins de la llista de cursos i pot fer que els estudiants el troben m&eacute;s f&agrave;cilment.
+17
View File
@@ -0,0 +1,17 @@
<P ALIGN=CENTER><B>Formats de curs de Moodle</B></P>
<P><B>Format semanal</B></P>
<UL>
El curs s'organitza setmana a setmana, amb una data de comen&ccedil;ament clara i una data de finalitzaci&oacute;. Cada setmana consta d'activitats. Algunes, com els diaris, poden tenir "finestres obertes", per exemple de dues setmanes, en acabant de les quals deixen d'estar disponibles.
</UL>
<P><B>Format per temes</B></P>
<UL>
Molt semblant al format semanal, excepte que cada "setmana" s'anomena tema.
Un "tema" no est&agrave; restringit per l&iacute;mits temporals. No cal especificar dates.
</UL>
<P><B>Format social</B></P>
<UL>
Aquest format est&agrave; orientat al voltant d'un f&ograve;rum principal, el f&ograve;rum Social, que apareix a la primera plana. &Eacute;s &uacute;til en situacions m&eacute;s informals. Ni tan sols cal que siguen cursos. Per exemple, es pot utilitzar com un tauler d'anuncis departamental.
</UL>
+3
View File
@@ -0,0 +1,3 @@
<P ALIGN=CENTER><B>Nom complet del curs</B></P>
<P>El nom complet del curs apareix a la part superior de la pantalla i en les llistes de cursos.</P>
+7
View File
@@ -0,0 +1,7 @@
<P ALIGN=CENTER><B>Not&iacute;cies del curs</B></P>
<P>Un f&ograve;rum especial anomenat "Not&iacute;cies" apareix en els formats de curs "setmanal" i "per temes". &Eacute;s un bon lloc per enviar anuncis i que els vegen tots els estudiants. (Tots els estudiants estan subscrits per defecte a aquest f&ograve;rum, i rebran els anuncis per correu electr&ograve;nic.)
<P>Aquest par&agrave;metre determina quantes not&iacute;cies recents apareixen a la primera plana del curs, dins d'un quadre de not&iacute;cies situat a baix a la dreta.
<P>Si el poses a "0 Not&iacute;cies", llavors no apareixer&agrave; el quadre.
+9
View File
@@ -0,0 +1,9 @@
<P ALIGN=CENTER><B>Nombre de setmanes/temes del curs</B></P>
<P>Aquest par&agrave;metre nom&eacute;s s'utilitza en els formats de curs "semanal" i "per temes".
<P>En el format "semanal", especifica el nombre de setmanes que durar&agrave; el curs, comen&ccedil;ant des de la data d'inici.
<P>En el format "per temes", especifica el nombre de temes del curs.
<P>En tots dos casos, aix&ograve; es tradueix en el nombre de "quadres" per davall de la meitat de la plana del curs.
+4
View File
@@ -0,0 +1,4 @@
<P ALIGN=CENTER><B>Nom curt del curs</B></P>
<P>Moltes institucions tenen una manera abreujada de referir-se a un curs, tal com BP102 o COMMS. Encara que el teu curs no tinga un nom aix&iacute;, posa-li'n un ac&iacute;. S'utilitzar&agrave; en diversos llocs en qu&egrave; el nom llarg no &eacute;s adequat (per exemple en la l&iacute;nia d'assumpte d'un correu electr&ograve;nic).</P>
+11
View File
@@ -0,0 +1,11 @@
<P ALIGN=CENTER><B>Data de comen&ccedil;ament del curs</B></P>
<P>Ac&iacute; &eacute;s on especifiques la data de comen&ccedil;ament del curs.</p>
<P>Si fas servir un format de curs "semanal", a&ccedil;&ograve; afectar&agrave; la visualitzaci&oacute; de les setmanes. La primera setmana comen&ccedil;ar&agrave; en la data que establisques ac&iacute;.</P>
<P>Aquest par&agrave;metre no afectar&agrave; els cursos que facen servir els formats "social" o "per temes".</p>
<P>Tanmateix, un detall que s&iacute; que ser&agrave; afectat &eacute;s la visualitzaci&oacute; dels diaris (logs), que fan servir aquesta data com la m&eacute;s antiga que es pot mostrar.</P>
<P>En general, si el teu curs t&eacute; una data de comen&ccedil;ament real, t&eacute; sentit fixar aquest par&agrave;metre, independentment del format de curs que faces servir.</P>
+11
View File
@@ -0,0 +1,11 @@
<P ALIGN=CENTER><B>Clau d'inscripci&oacute; en el curs</B></P>
<P>Una clau d'inscripci&oacute; mant&eacute; el p&uacute;blic no desitjat al marge del curs.</P>
<P>Si la deixes en blanc, qualsevol persona que s'haja creat un nom d'usuari de Moodle en aquest lloc podr&agrave; inscriure's en el teu curs simplement entrant-hi.</p>
<P>Si hi poses alguna cosa, aleshores es demanar&agrave; aquesta paraula o frase als estudiants que intenten entrar-hi per primera vegada (NOM&Eacute;S LA PRIMERA VEGADA).</P>
<P>La idea &eacute;s que proporciones la clau a les persones autoritzades utilitzant altres mitjans com ara el correu electr&ograve;nic, el correu postal, el tel&egrave;fon o fins i tot verbalment en la classe presencial.</P>
<p>Si aquesta contrasenya "s'escampa" i s'inscriuen persones no desitjades, pots esborrar-les del curs (per mitj&agrave; de la seua p&agrave;gina de perfil d'usuari) i canviar la clau. Els estudiants que s'hagueren inscrit leg&iacute;timament no es veuran afectats, per&ograve; els altres no podran tornar a entrar-hi.</P>
+5
View File
@@ -0,0 +1,5 @@
<P ALIGN=CENTER><B>Permetre nous debats</B></P>
<P>En la majoria dels f&ograve;rums voldr&agrave;s que els no professors puguen comen&ccedil;ar nous temes de debat (fils).
<P>A vegades, per&ograve;, voldr&agrave;s inhabilitar aquesta opci&oacute;. Per exemple, aix&ograve; &eacute;s &uacute;til en el F&ograve;rum de not&iacute;cies si vols que nom&eacute;s els professors puguen posar not&iacute;cies a la primera plana del curs. Els estudiants, en tot cas, sempre podran enviar respostes als missatges dels professors.
+11
View File
@@ -0,0 +1,11 @@
<P ALIGN=CENTER><B>Fitxers adjunts en els missatges</B></P>
<P>Opcionalment pots adjuntar UN fitxer del teu ordinador quan envies un missatge a un f&ograve;rum. Aquest fitxer es puja al servidor i es guarda amb el teu missatge.
<P>Aix&ograve; &eacute;s &uacute;til quan vols compartir una imatge, per exemple, o un document de Word.
<P>El fitxer pot ser de qualsevol tipus, per&ograve; en tot cas &eacute;s molt aconsellable que tinga la t&iacute;pica extensi&oacute; de tres lletres, per exemple .doc per als documents Word, .gif o .jpg per a imatges, etc. Aix&ograve; far&agrave; m&eacute;s f&aacute;cil que els altres puguen baixar i veure els fitxers adjunts en els seus navegadors.
<P>Si tornes a editar un missatge i hi adjuntes un nou fitxer, llavors aquest reempla&ccedil;ar&agrave; l'anterior.
<P>Si tornes a editar un missatge que t&eacute; un fitxer adjunt i deixes en blanc el camp de fitxer adjunt, llavors es conservar&agrave; el fitxer original.
+11
View File
@@ -0,0 +1,11 @@
<P ALIGN=CENTER><B>Tipus de f&ograve;rums</B></P>
<P>Es poden triar diversos tipus de f&ograve;rums:
<P><B>Un debat simple</B> - &eacute;s un sol tema, tot en una p&agrave;gina. &Uacute;til per a debats breus i enfocats.
<P><B>F&ograve;rum est&agrave;ndard per a &uacute;s general</B> - &eacute;s un f&ograve;rum obert en el qual tothom pot iniciar un nou tema en qualsevol moment. Aquest &eacute;s el millor f&ograve;rum de prop&ograve;sit gen&egrave;ric.
<P><B>Cada persona envia un debat</B> - Cada persona pot enviar exactament un tema de debat (i tothom pot enviar-hi respostes). Aquest &eacute;s &uacute;til quan vols que cada estudiant inicie un debat, centrat per exemple en les seues reflexions sobre el tema de la setmana, i tots els altres li responen.
<P>(Hi haur&agrave; m&eacute;s desenvolupament en aquesta &agrave;rea en futures versions de Moodle.)
+70
View File
@@ -0,0 +1,70 @@
<P ALIGN=CENTER><B>Forum Ratings</B></P>
<P>Individual posts can be rated using a scale based on the theory of
<strong>separate and connected knowing</strong>.
<p>This theory may help you to look at human interactions
in a new way. It describes two different ways that we can evaluate and learn
about the things we see and hear.
<p>Although each of us may use these two methods in different amounts at different
times, it may be useful to imagine two people as examples, one who is a mostly
separate knower (Jim) and the other a mostly connected knower (Mary).</p>
<ul>
<li>Jim likes to remain as 'objective' as possible without including his feelings
and emotions. When in a discussion with other people who may have different
ideas, he likes to defend his own ideas, using logic to find holes in his
opponent's ideas. He is critical of new ideas unless they are proven facts
from reputable sources such as textbooks, respected teachers or his own direct
experience. Jim is a very <strong>separate knower</strong>.<br><br>
</li>
<li>Mary is more sensitive to other people. She is skilled at empathy and tends
to listen and ask questions until she feels she can connect and &quot;understand
things from their point of view&quot;. She learns by trying to share the experiences
that led to the knowledge she finds in other people. When talking to others,
she avoids confrontation and will often try to help the other person if she
can see a way to do so, using logical suggestions. Mary is a very <strong>connected
knower</strong>.</li>
</ul>
<p>Did you notice in these examples that the separate knower is male and the connected
knower is female? Some studies have shown that statistically this tends to be
the case, however individual people can be anywhere in the spectrum between
these two extremes. </p>
<p>For a collaborative and effective group of learners it may be best if everyone
were able to use BOTH ways of knowing.</p>
<p>In a particular situation like an online forum, a single post by a person may
exhibit either of these characteristics, or even both. Someone who is generally
very connected may post a very separate-sounding message, and vice versa. The
purpose of rating each post using this scale is to:</p>
<blockquote>
<p>a) help you think about these issues when reading other posts<br>
b) provide feedback to each author on how they are being seen by others</p>
</blockquote>
<p>The results are not used towards student assessment in any way, they are just
to help improve communication and learning.</p>
<hr>
<p><br>
In case you're interested, here are some references to papers by the authors
who originally developed these ideas:</p>
<ul>
<li>Belenky, M.F., Clinchy, B.M., Goldberger, N.R., &amp; Tarule, J.M. (1986).
Women's ways of knowing: the development of self, voice, and mind. New York,
NY: Basic Books.</li>
<li>Clinchy, B.M. (1989a). The development of thoughtfulness in college women:
Integrating reason and care. American Behavioural Scientist, 32(6), 647-657.</li>
<li>Clinchy, B.M. (1989b). On critical thinking &amp; connected knowing. Liberal
education, 75(5), 14-19.</li>
<li>Clinchy, B.M. (1996). Connected and separate knowing; Toward a marriage
of two minds. In N.R. Goldberger, Tarule, J.M., Clinchy, B.M. &amp;</li>
<li>Belenky, M.F. (Eds.), Knowledge, Difference, and Power; Essays inspired
by &#8220;Women&#8217;s Ways of Knowing&#8221; (pp. 205-247). New York, NY:
Basic Books.</li>
<li>Galotti, K. M., Clinchy, B. M., Ainsworth, K., Lavin, B., &amp; Mansfield,
A. F. (1999). A New Way of Assessing Ways of Knowing: The Attitudes Towards
Thinking and Learning Survey (ATTLS). Sex Roles, 40(9/10), 745-766.</li>
<li>Galotti, K. M., Reimer, R. L., &amp; Drebus, D. W. (2001). Ways of knowing
as learning styles: Learning MAGIC with a partner. Sex Roles, 44(7/8), 419-436.
<br>
</li>
</ul>
+9
View File
@@ -0,0 +1,9 @@
<P ALIGN=CENTER><B>Subscripci&oacute; als f&ograve;rums</B></P>
<P>Quan una persona &eacute;s subscrita a un f&ograve;rum aix&ograve; vol dir que se li enviaran c&ograve;pies dels missatges del f&ograve;rum per correu electr&ograve;nic (les c&ograve;pies s'envien mitja hora despr&eacute;s que s'escriu el missatge).
<P>Normalment la gent pot triar si vol o no vol estar subscrita a cada f&ograve;rum.
<P>Tanmateix, si un processor for&ccedil;a la subscripci&oacute; a un f&ograve;rum concret, l'opci&oacute; desapareix i tots els membres de la classe reben c&ograve;pies per correu electr&ograve;nic.
<P>Aix&ograve; &eacute;s especialment &uacute;til per al F&ograve;rum de not&iacute;cies i per a tots els f&ograve;rums actius durant el comen&ccedil;ament del curs, mentre tots s'adonen que existeix la possibilitat de subscriure's individualment per correu.
+11
View File
@@ -0,0 +1,11 @@
<P ALIGN=CENTER><B>Acc&eacute;s d'invitats</B></P>
<P>Tens l'opci&oacute; de permetre "invitats" en el teu curs.
<P>La gent pot entrar-hi com a invitada per mitj&agrave; del bot&oacute; "Entrar com a invitat" en la pantalla d'entrada.
<P>Els invitats SEMPRE tenen acc&eacute;s "nom&eacute;s de lectura" - aix&ograve; vol dir que no podran deixar missatges ni embolicar de cap manera el curs als estudiants reals.
<P>A&ccedil;&ograve; pot resultar pr&agrave;ctic quan vulgues deixar entrar col&middot;legues perqu&egrave; vegen la teua feina, o per deixar veure el curs als estudiants abans que decidisquen inscriure-s'hi.
<P>Tin en compte que tens l'opci&oacute; de dos tipus d'acc&eacute;s d'invitats: amb la clau d'inscripci&oacute; o sense. Si tries de permetre invitats que tinguen la clau, aleshores l'invitat haur&agrave; de donar la clau d'inscripci&oacute; CADA VEGADA que entra al curs (no com els estudiants, que nom&eacute;s l'han donar la primera vegada). Aix&ograve; et permet limitar els invitats. Si tries de permetre invitats sense clau, aleshores qualsevol podr&agrave; entrar directament en el curs.

Some files were not shown because too many files have changed in this diff Show More