Commit graph

1684 commits

Author SHA1 Message Date
sam marshall
a3c17aed9f MDL-33116 Media filter broken with slasharguments off 2012-05-21 14:24:42 +01:00
sam marshall
ffe4de973b MDL-29624 Media embedding system, part 0: Add get_path() to moodle_url
(It may not seem directly related, but this function is needed for the
media embedding system.
2012-05-09 18:22:12 +01:00
Petr Skoda
f0202ae9a2 MDL-30686 improve accuracy of qualified_me() by trying PAGE->url first
This should help SSL proxies and returning to current page after require_login().
2012-04-27 13:39:18 +02:00
Petr Skoda
590abcf801 MDL-32427 fix suport for extra schemes in links in HTML Purifier 2012-04-23 10:29:43 +02:00
Sam Hemelryk
3211569a6a Revert "MDL-30843 and MDL-30842 - accessibility compliance: Add <label> for form input text and select tag"
This reverts commit f9f281b8fe.
2012-04-11 17:18:58 +12:00
Sam Hemelryk
5bfeb5ffd3 Merge branch 'MDL-30843_b' of git://github.com/rwijaya/moodle 2012-04-10 12:34:37 +12:00
Petr Skoda
a3d5830a0a MDL-32149 PHPUnit test support - part 2
Includes:
* constants refactoring
* reworked db table init
* support for $CFG->debug = -1
* functional DB tests
* fixed $DB->get_indexes() to not throw exceptions when table does not exist
* fix handling of user passwords in test db
* add debug info to exception messages
* removed unnecessary PHP debug errors from mathslib
* fixed @error suppression in get_string
* fixed PHPUnit error handler setup
* added timezone info to default install
2012-04-03 22:30:53 +02:00
Rossiani Wijaya
f9f281b8fe MDL-30843 and MDL-30842 - accessibility compliance: Add <label> for form input text and select tag 2012-03-30 16:26:58 +08:00
Petr Skoda
986f8ea285 MDL-32109 do not use HTMLPurifier for some safe and valid html fragments 2012-03-24 11:29:59 +01:00
Petr Skoda
5bd4040866 MDL-31857basic phpunit support
Thanks Eloy Lafuente, Tim Hunt and Sam Hemelryk for valuable feedback and ideas.
2012-03-21 10:31:37 +01:00
Petr Skoda
6f3451e540 MDL-31301 remove all uses of moodle_strtolower() and deprecated it 2012-03-03 11:46:26 +01:00
Petr Skoda
f8311defeb MDL-31301 use static textlib methods 2012-03-03 11:46:13 +01:00
Eloy Lafuente (stronk7)
6c941fc10f Merge branch 'MDL-29161' of git://github.com/timhunt/moodle 2012-02-27 22:10:47 +01:00
Dan Poltawski
5dad45912c MDL-29592 weblib: prevent warnings when $USER not set 2012-02-27 16:11:36 +01:00
Tim Hunt
ab82976f92 MDL-29161 weblib: moodle_ulr::out does not cope with array params. 2012-02-23 12:07:28 +00:00
Dan Poltawski
48ddc9bfd6 MDL-29091 weblib - Introduce out_as_local_url() method to moodle_url
This can be used for passing around PARAM_LOCALURL's where necessary
stripping the wwwroot
2012-01-13 10:16:52 +00:00
Tim Hunt
d07f7be890 MDL-31101 format_string: Don't mangle < and > in strings like x < 1. 2012-01-10 14:52:19 +00:00
Petr Skoda
4e8d084bc9 MDL-21617 remove problematic attempt to remove script events from random text
This "feature" was used to partially eliminate XSS attacks on vulnerable code. Developers MUST use clean_text() on HTML text fragments only, it can not be used on random html tag attributes.

This change may simplify a bit exploiting of vulnerable code, but every XSS cheat sheet contains information how to work around this outdated anti-XSS measure.

Please note this change fixes many problems with valid uses of language= or onXXXXX= such as in urls, tex, code samples, etc.
2011-11-19 13:22:33 +01:00
Petr Skoda
581e8dba38 MDL-29925 improve redirect url cleanup 2011-10-28 19:32:07 +02:00
Eloy Lafuente (stronk7)
94da1daf40 Merge branch 'w42_MDL-29866_m22_setupinit' of git://github.com/skodak/moodle 2011-10-25 16:41:11 +02:00
Petr Skoda
73b309e6a3 MDL-28627 remove buggy and obsolete KSES cleaning 2011-10-22 09:25:06 +02:00
Petr Skoda
f0f8f9a796 MDL-29866 page setup improvements
incorrect PAGE init - it should be done at the very end; redirect() should not use OUTPUT before PAGE init; SITEID should be deprecated in favour of $SITE->id (this is going to cause troubles in tenant switching in CLI, cron and tests); missing "global $SITE"'; minor coding style issues; PHPDocs; it also helps with merging/testing of multitenant patch
2011-10-21 16:35:19 +02:00
Sam Hemelryk
62b214d9a6 Merge branch 'w36_MDL-29014_m22_str' of git://github.com/skodak/moodle 2011-09-13 12:45:34 +12:00
Tom Lanyon
365bec4c06 MDL-28701 Change all uses of $CFG->dataroot/cache to $CFG->cachedir 2011-09-10 10:35:46 +02:00
Petr Skoda
138c76789b MDL-29014 fix a few incorrect uses of strlen and substr 2011-09-10 10:21:31 +02:00
Dan Poltawski
a276778aea MDL-28059 weblib - don't strip mailto: anchors 2011-08-06 21:14:01 +01:00
Sam Hemelryk
0704038e41 Merge branch 'w28_MDL-28345_m22_utf8' of git://github.com/skodak/moodle 2011-07-18 21:16:43 +10:00
Petr Skoda
78fcdb5fdb MDL-28345 make sure input parameters do not contain invalid utf-8 chars 2011-07-15 15:00:49 +02:00
Petr Skoda
5c754932e7 MDL-28344 new option to prevent clickjacking via frame embedding 2011-07-14 22:01:23 +02:00
Petr Skoda
98eaf27e3c MDL-28280 remove obsolete unmaintained $CFG->usesid 2011-07-10 13:44:41 +02:00
Aparup Banerjee
728ebac7f2 MDL-28135 general Updating all hardcoded "docs.moodle.org/en/Development:" type doc links to "docs.moodle.org/dev/" 2011-07-05 14:27:31 +08:00
Aparup Banerjee
eea3341dfc MDL-28044 general - updated print_error() link to point to new versioned docs link. 2011-06-29 10:55:02 +08:00
Tim Hunt
6481b28fe5 MDL-27878 make progress bars fail explicity if you forget to call create(). 2011-06-16 18:55:29 +01:00
Sam Hemelryk
f6bd0b9e39 Merged branch 'MDL-27695' of git://github.com/nebgor/moodle.git with changes 2011-06-08 16:25:57 +08:00
Aparup Banerjee
3b6711d5ce MDL-27695 Documentation : updated the moodle docs link at the footer of pages to point to new docs url 2011-06-08 13:44:35 +08:00
Petr Skoda
7df50029b4 MDL-25826 integrate HTMLPurifier 4.3.0 and improve performance
The new HTMLPurifier finally caches the schema properly eliminating both extra CPU cycles and disk writes. The repeated dir exists tests might cause problems on NFS shares.
2011-04-09 11:45:24 +02:00
David Mudrak
5c6ee6ec36 MDL-26964 URL returned by moodle_url::out_omit_querystring() may contain the anchor part 2011-03-24 14:51:39 +01:00
Eloy Lafuente (stronk7)
e5e64a4886 Merge branch 'w11_MDL-26697_20_media' of git://github.com/skodak/moodle
Conflicts:
	theme/formal_white/config.php
2011-03-15 15:21:02 +01:00
Sam Hemelryk
4bbe460316 Merge branch 'w11_MDL-26480_20_redirect' of git://github.com/skodak/moodle 2011-03-14 15:41:51 +08:00
Petr Skoda
b399e43592 MDL-26480 IIS redirect bug workaround
Credit goes to Zenger Sergey
2011-03-13 10:47:47 +01:00
Petr Skoda
fcd2cbaf1f MDL-26697 multiple media filtering fixes and improvements
Bug fixes:
    * fixed broken flash resizing via URL
    * upgraded Flowplayer
    * fixed invalid context in format_text()
    * all media related CSS moved from themes to filter and resources
    * fixed automatic pdf resizing in resources

Changes:
    * reworked filter_mediaplugin system settings - grouped by player type instead of individual extensions, added more information
    * improved regex url matching
    * removed old unused players, Eolas fix and UFO embedding
    * image embedding moved to filter_urltolink
    * new Flowplayer embedding API
    * accessibility and compatibility tweaks in Flowplayer
    * SWF embedding now works only in trusted texts, it is now enabled by default (works everywhere if "Allow EMBED and OBJECT tags" enabled)
    * new default video width and height

New features:
    * automatic Flash video resizing using information from video metadata
    * Flash HD video support (*.f4v)
    * Flash video embedding with HTML5 fallback - compatible with iOS and other mobile devices
    * Vimeo embedding
    * no-cookie YouTube site supported
    * HTML 5 audio and video with multiple source URLs and QuickTime fallback
    * more video and audio extensions in filelib.php
    * MP3 player colours customisable via CSS in themes
    * nomediaplugin class in a tag prevents media embedding
2011-03-12 17:42:52 +01:00
Rossiani Wijaya
6e571603c0 MDL-19555: add NULL string test to format_test(). Credit goes to Matej Vela. Thanks 2011-03-11 11:16:18 +08:00
sam marshall
b031caf858 lib MDL-26423 Added support for ->allowid option in format_text 2011-03-04 15:53:10 +00:00
Petr Skoda
2453531f03 Merge branch 'MDL-26337' of git://github.com/timhunt/moodle 2011-02-14 22:15:30 +01:00
Petr Skoda
ad9ab4dfe5 MDL-26131 fix several collapsible_region issues
1/ the $default was not passed from print_collapsible_region()
2/ incorrect php docs describing $userpref
3/ missing empty() check on $userpref
2011-02-13 11:52:09 +01:00
Tim Hunt
8711360225 MDL-26337 Improve close_window. Fix bug when $reloadopener is false, and better usability when it is true. 2011-02-09 19:02:31 +00:00
Petr Skoda
46df3c6059 Merge branch 'MDL-25981' 2011-01-31 22:44:17 +01:00
Petr Skoda
893fe4b6b2 MDL-26069 detect missing file postprocessing 2011-01-29 17:50:12 +01:00
sam marshall
0d8b6a69ce lib MDL-25981 Improved modinfo
This commit:
a) moves modinfo code into new library modinfolib.php
b) uses classes instead of stdClass objects, allowing a huge amount of documentation (and IDE completion)
c) adds hooks so that plugins other than forum can display messages like forum's 'unread', and plugins other than label can display html (apart from/as well as their view.php link) on the course view page
d) removes current hacks for forum and label (mainly in print_section but also across the code), replacing with new 'content' and similar variables [this is the reason for the changes in blocks, etc]
e) reduces size of modinfo in database (only when rebuilt) by excluding empty fields

The change is intended to be backward compatible and does not affect the format of modinfo in database.
2011-01-26 10:29:16 +00:00
sam marshall
27d6ab5712 lib MDL-26044 Optimise moodle_url based on profiler data 2011-01-18 12:39:51 +00:00