Commit graph

1351 commits

Author SHA1 Message Date
skodak
5ca3c8386f MDL-19184, MDL-19212 - refactoring, cleanup and improvements in text editors support; localization support is not finished, inline docs incomplete, expect more commits soon 2009-05-16 20:53:21 +00:00
skodak
c92ac318a9 MDL-19194 fixed regression - recursive cretion of dirs on win32 works again 2009-05-15 07:21:29 +00:00
tjhunt
f474a4e583 blocks: MDL-19010 Fix further blocks-related breakage, including removing all references to blocks_insance_old outside blocklib.php 2009-05-07 08:55:10 +00:00
tjhunt
93d4a373f9 blocklib: MDL-19010 always include blocklib in setup.php, stip includes elsewhere 2009-05-06 09:13:16 +00:00
tjhunt
66b10689e2 blocklib: MDL-19010 upgrade database tables ready for now blocks system 2009-05-06 09:12:03 +00:00
tjhunt
830dd6e9cd moodle_page: MDL-12212 reimplement user_is_editing, deprecate isediting 2009-05-06 08:59:29 +00:00
tjhunt
948203a5e8 moodle_page: MDL-12212 ->category and ->categories 2009-05-06 08:46:05 +00:00
tjhunt
89fbdca300 moodle_page: MDL-14305 (and MDL-12212) class on body based on ->wwwroot 2009-05-06 08:44:58 +00:00
tjhunt
e88462a055 moodle_page: MDL-12212 eliminate the two different interpretations of
pagetype
2009-05-06 08:41:02 +00:00
tjhunt
c13a5e71cc moodle_page: MDL-12212 start of new moodle_page class
* has course and status fields
* $PAGE->status updated by print_header and footer
* $PAGE->set_course now replace course_setup function
* global $PAGE created in setup.php
* unit tests for functionality so far
* Moodle still seems to work after this commit!
2009-05-06 08:29:22 +00:00
stronk7
6bdf4c99b3 MDL-16824 messaging - move unread messages from deleted users to message_read.
Pending to commit changes to uploaduser.php. Credit goes to Anthony Borrow. Thanks!
Merged from 19_STABLE
2009-04-26 22:56:56 +00:00
skodak
dc5c2bd9eb MDL-18910 full support for module intro editor with embedded images 2009-04-21 21:17:21 +00:00
skodak
42f103be4c MDL-18910 moving modedit features to modname_supports() 2009-04-21 08:57:20 +00:00
tjhunt
0f74bb01ff filters: MDL-7336 settings page for setting the local enabled/disabled state 2009-04-13 07:12:41 +00:00
tjhunt
ccc161f8f0 filters: MDL-7336 change weblib to use the new code
* Rename filter base class from filter_base to moodle_text_filter
* Remove unnecessary explicit constructors in moodle_text_filter
subclasses
* New filter_manager class, rather than static methods in filter_base
* Move some logic out of weblib, and into filter_manager
* Count filtering ops when $CFG->perfdebug on, via
performance_measuring_filter_manager
* Kill unused filter_string function. Petr said it should have been
private to weblib
2009-04-13 06:56:32 +00:00
tjhunt
5c2fec8b74 get_string: MDL-18813 get_string was broken for strings that were '' 2009-04-08 11:45:53 +00:00
sam_marshall
2bf69a8588 MDL-18094: course/viewhiddenactivities didn't work (in some parts of the code) at module level 2009-04-03 13:11:05 +00:00
tjhunt
c464eda684 get_string: MDL-18669 - fixing a screw-up spotted by Dongsheng. Thanks. 2009-04-03 07:41:40 +00:00
fmarier
c65ab2be95 Password policy: MDL-17602 new "max consecutive identical characters" setting 2009-04-03 02:22:52 +00:00
sam_marshall
48f9c073ca MDL-18094: course/viewhiddenactivities didn't work (in some parts of the code) at module level 2009-04-02 16:32:12 +00:00
tjhunt
d8413bf3d2 lang editing: MDL-18776 fix regression from MDL-18669. 2009-04-02 09:37:29 +00:00
tjhunt
0c34c7eb50 translation: MDL-18766 reverting. I guess it was not yet ready for prime-time.
I'll commit the patch to contrib in case anyone wishes to experiment further.
2009-04-02 02:42:11 +00:00
tjhunt
b4cf937102 translation: MDL-18766 Prototype automatic translation system for Moodle.
If Google can do something like http://translate.google.com/, surely we
can do something just as good in Moodle. Here is a first attempt. It is
a bit rough around the edges, and only a couple of target lananguages
have been implemented so far. (More and better attempts welcome!)

In order to ensure that this gets adequate testing, I have made sure that
it gets turn on by default. However, if you really don't like it, you can
turn it off under Administration > Development -> Experimental settings.
2009-04-01 00:39:17 +00:00
tjhunt
b810a4d3c9 filters: MDL-17684 Look for the filter name in filter_myfilter.php first.
This makes filters more plugginable, becuase with this lang file name, get_string will look for the filter name in filter/myfilter/lang/en_utf8/filter_myfilter.php.

To do this, there is a new function filter_get_name in filterlib that contains the logic.

Also, a new function filter_get_all_installed to replace the logic for getting all filters that was duplicated in three places.

filter_get_name no longer does such a nice fall-back if the name is missing, to encourage people to supply the right string. The fallback now looks like '[[filtername]] (filter/tidy)'.
2009-03-30 08:33:13 +00:00
tjhunt
e7b818807c get_string: MDL-13816 allow third-partly modules to register sub-plugin types that have their own lang files.
I suppose to be really useful we should deal with database, capabiltities, etc. too in due course. Still, this is a start.
2009-03-30 06:13:35 +00:00
tjhunt
bb45fe62c4 get_string: Refactoring, performance improvements, bug fixes and unit tests
MDL-18669 get_string refactored to elimiate duplicate code and make it easier to understand.
MDL-17763 parent language not processed correctly when getting a plugin string.
MDL-16181 more intelligent caching to avoid repeated file_exists checks.
MDL-12434 move values to array keys to improve lookup times.

The main part of the refactoring is to create a singleton string_manager class to encapsulate the cached data and the processing, while breaking the code up into more smaller methods.

Other performance improvements include:
* Cache results of plugin name -> locations to search array.
* Cache parent lang lookup.
* Skip eval if the string does not contain $ \ or %.
* Remove the unnecessary sprintf from the eval.

There is a performance testing script in lib/simpletest/getstringperformancetester.php. For now this script has the old get_string implementation copied and pasted to the end, and renamed to old_get_string to allow for comparitive timings.

There are now some unit tests for get_string in lib/simpletest/teststringmanager.php. I think I have managed to cover most of the tricky cases.
2009-03-30 02:21:27 +00:00
poltawski
9b831e01d2 lib/moodlelib.php MDL-18406 - use more robust require path
thanks to Daniel Neis
merged from MOODLE_19_STABLE
2009-03-25 09:38:41 +00:00
poltawski
eac4623d29 lib/email_to_user MDL-10384 Recipeint names broken
When emailcharset is not utf8 the charset conversion was breaking
recipient/replyto names

thanks to Tatsuya Shirai
merged from MOODLE_19_STABLE
2009-03-25 09:18:19 +00:00
poltawski
2029fcf47f email_to_user: MDL-16328 - prevent empty receeipent address
Be a bit defensive as it seems to be possible for this to happen
with LDAP auth
2009-03-19 10:35:08 +00:00
stronk7
1263a0ff1d MDL-18518 user firstaccess - added suport to display user->firstaccess. Credit goes to Anthony Borrow!
Merged from 19_STABLE
2009-03-11 11:22:55 +00:00
stronk7
e0ec2d45b8 MDL-18440 email_to_user() - avoid some notices ; merged from 19_STABLE 2009-03-04 15:03:00 +00:00
skodak
8f0632f097 MDL-18318 fixed incorrect function param - thanks Aurelijus 2009-02-19 16:21:46 +00:00
skodak
9c6972d630 MDL-18293 exception and DML cleanup 2009-02-17 17:32:36 +00:00
skodak
013376dec4 MDL-18293 exception and DML cleanup 2009-02-17 17:23:56 +00:00
skodak
5e2f308b91 MDL-18293 exception and DML cleanup 2009-02-17 16:50:36 +00:00
tjhunt
0a0cf09a6f moodlelib.php: Improve the phpdoc comment for userdate. 2009-02-11 08:08:58 +00:00
nicolasconnault
ec0123208d MDL-18188 Added a new function with matching unit tests, following Sam's comment in the tracker 2009-02-10 15:33:25 +00:00
skodak
ed8453a625 MDL-17573 fixed problem when en_utf8 sopecified as parent 2009-02-08 22:48:17 +00:00
skodak
07f6711889 MDL-17573 added automatic downloading of parent languages 2009-02-08 22:33:54 +00:00
skodak
cc8727451f MDL-17565 automatic download of parent lang + parent lang cleanup 2009-02-07 18:55:21 +00:00
skodak
3b09331066 MDL-17458 rewritten installer 2009-02-07 10:20:33 +00:00
poltawski
244d15093f mnet/forum MDL-18118 - email links were rewritten to use IDP when SITEID not 1
Switched check to use is_mnet_remote_user()
2009-02-02 17:47:12 +00:00
skodak
b3d960e64a fixed whitespace 2009-02-01 13:36:07 +00:00
skodak
038a29d580 MDL-17808 more lastname support when resetting passwords; merged from MOODLE_19_STABLE 2009-01-31 21:38:12 +00:00
skodak
88582df496 MDL-17458 refactored guest and admin user creation + refactored roles install + added protection for installation hijacking + added reliable session test right before editting of admin account 2009-01-29 22:54:41 +00:00
tjhunt
285b83adf5 Fix incorrect comment. 2009-01-21 07:41:09 +00:00
tjhunt
d61f7b7641 backup/restore: MDL-16614 more reliable test for when we are restoring a backup that was made of the same site that we are restoring to.
* Use this to fix a question restore bug.
* Replace older code that does something similar with the new test.
* Refactor initialisation of $CFG->siteidentifier into a function. There were about 4 copies of this code ;-)
2009-01-20 03:16:30 +00:00
moodler
d44cee76fa repository/picasa MDL-17473 Use picasa description as the filename if it exists 2009-01-19 06:19:26 +00:00
skodak
dd9e22f871 MDL-17942 implemented gc and timeouts for db sessions 2009-01-18 11:19:40 +00:00
skodak
56949c17de MDL-14992 refactored use of session_write_close() 2009-01-17 15:25:08 +00:00