Commit Graph

29 Commits

Author SHA1 Message Date
David Woloszyn 64a13123f3 MDL-79759 repository_url: Limit css imports and remove fragments
There are checks to urls that attempt to limit recurrsion when
parse_file is called. This is problematic for css import urls that
can call an indefinite amount of nested import urls. An import limit
has been introduced to address this. Fragments have also been removed.
2023-12-06 03:54:20 +01:00
Meirza 59c6b2dccd MDL-77342 repository: Added class properties that are not declared.
In PHP 8.2 and later, setting a value to an undeclared class property is
deprecated and emits a deprecation notice.
So we need to add missing class properties that still need to be declared.
2023-03-26 14:48:29 +07:00
Marina Glancy a800e7e62f MDL-74853 various: add second parameter to htmlentities functions
Default value of the $flag argument changed in PHP 8.1 from ENT_COMPAT to ENT_QUOTES | ENT_SUBSTITUTE
To ensure consistent behavior across different PHP version the second parameter is now required for the functions:
htmlspecialchars(), htmlentities(), htmlspecialchars_decode(), html_entity_decode() and get_html_translation_table()
2022-11-28 16:12:20 +01:00
Huong Nguyen 9b758d5cc8 MDL-71922 file: Enhance endless recursion requests protection 2021-07-08 23:30:35 +02:00
Russell Smith 1fcf0ca8a5 MDL-35628 performance: Remove dirname() where possible.
dirname() is a slow function compared with __DIR__ and using
'/../'.  Moodle has a large number of legacy files that are included
each time a page loads and is not able to use an autoloader as it is
functional code.  This allows those required includes to perform as
best as possible in this situation.
2016-06-10 08:06:49 +10:00
John Okely be305dc13a MDL-41846 repository_url: Escape > < ' " in input url
And throw an exception when a url is incorrectly formatted
2014-12-05 11:15:30 +08:00
John Okely 80a0fee266 MDL-41846 repository_url: Convert spaces to %20 in input url 2014-12-05 10:24:46 +08:00
Tim Hunt 5bcfd504df MDL-45618 Fix @since PHPdoc tags. 2014-05-19 17:03:04 +01:00
Frederic Massart c5e8a036c5 MDL-45332 repository_url: URL parameter is using PARAM_URL 2014-05-08 15:35:03 +08:00
Matthew Noorenberghe 9b3d60fc47 MDL-41634 - URL Download Repository doesn't warn when asked to download non-image files 2013-09-05 21:37:39 -07:00
Frederic Massart 31581ae65d MDL-36426 repository: Prevent login_as() users to access private repositories 2013-03-04 02:38:35 +01:00
Dan Poltawski c75599f966 Merge branch 'wip-MDL-34047-master' of git://github.com/marinaglancy/moodle 2012-07-04 09:51:25 +08:00
Kevin Wiliarty b1eeb76ec2 MDL-33749 follow redirects for URL downloader 2012-07-03 14:16:51 -04:00
Marina Glancy 81c4a77827 MDL-34047 repository URL downloader must say that it returns only images 2012-07-02 14:12:20 +08:00
Dongsheng Cai d6453211b6 MDL-33513: Make files->source field consistent 2012-06-15 14:51:07 +08:00
Dan Poltawski 414ce30812 Revert MDL-33513
This reverts commit b2cf2b807f.
This reverts commit 24b96f0170.
This reverts commit 39c60294a6.
This reverts commit 8a288971e2.
2012-06-14 13:57:45 +08:00
Dongsheng Cai 8a288971e2 MDL-33513: Make files->source field consistent 2012-06-10 17:47:00 +10:00
Dongsheng Cai 6723372514 MDL-28666 Extends repository to support references
1. Allow repository to create references to external contents
2. Extends files API to handle file references
3. Generic file caching
4. Backup/restore file references
5. Download external contents if repository uninstalled
6. Allow filepicker to display iframe
7. PHPUnit test suits
2012-05-21 11:57:51 +08:00
Marina Glancy 8685679a2a MDL-31928: Fixing bugs in repository_url
- if the same image occurs several times on the page list it only once
- resolve image path correctly if it has a query string
- show images included in CSS
- non-JS file picker ignores thumbnail width and height attributes (this is a temp fix until renderers are implemented)
2012-04-23 09:33:27 +08:00
Petr Skoda 6bdfef5da9 MDL-24321 switching to standard stdClass() 2010-09-21 08:54:01 +00:00
Petr Skoda d078f6d38e standardized PHPDocs package info 2010-09-06 11:29:21 +00:00
Petr Skoda ede7252234 MDL-23784 finally getting rid of all legacy .gif and .png extensions, yay! fixing issues with incorrect &amp; in JS code 2010-08-12 20:37:24 +00:00
Dongsheng Cai b923cf621c "MDL-13766, removed unused client_id variable" 2010-08-03 08:14:08 +00:00
Dongsheng Cai a5adfa2658 MDL-23072, properly localised repository instance name 2010-07-27 09:03:54 +00:00
Dongsheng Cai e35194bec4 MDL-22982
1. rename repository.class to lib.php
2. fixed repository_callback.php
3. repository_ajax use moodle default exception handler
4. improve file_get_user_used_space performance
2010-07-05 07:27:49 +00:00
Dongsheng Cai 10d53fd349 "MDL-19235, add boilerplates to repository module files" 2009-12-17 03:40:38 +00:00
Petr Skoda 4317f92f3f MDL-20700 coding style cleanup - cvs keywords removed, closign php tag removed, trailing whitespace cleanup 2009-11-01 12:51:40 +00:00
dongsheng 4769306136 "MDL-19180, url plugin, grab image resources only" 2009-07-01 03:46:20 +00:00
dongsheng 129deb0273 "MDL-19180, convert relative url to absolute url in url plugin" 2009-06-29 03:32:38 +00:00