Commit Graph

88 Commits

Author SHA1 Message Date
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
Andrew Nicols
6b587d2be2 MDL-53696 forum: Check discussion in forum 2016-05-06 09:27:25 +08:00
Andrew Nicols
d954b54f9e MDL-30811 forum: Update use of redirect to include message and type 2016-02-29 09:05:57 +08:00
Simey Lameze
dcee0b9447 MDL-49360 core_lib: add new method get_local_referer()
This commit also replace all usages of $_SERVER['HTTP_REFERER'] and get_referer().
2015-07-27 11:11:24 +08:00
Sam Hemelryk
783d96c6da Merge branch 'MDL-48309-master' of git://github.com/andrewnicols/moodle 2014-12-01 11:10:25 +13:00
Andrew Nicols
6220813776 MDL-48309 mod_forum: Handle discussion subscriptions correctly 2014-11-25 09:23:51 +08:00
Mario Wehr
772e9dc17e MDL-48274 mod_forum: Add missing context to has_capability call 2014-11-19 14:06:07 +08:00
Marina Glancy
93a4f8b5fc Merge branch 'MDL-47390-master' of git://github.com/andrewnicols/moodle 2014-11-05 16:35:05 +08:00
Andrew Nicols
2a9f525bcf MDL-47390 mod_forum: Correct check for groups when subscribing 2014-10-31 08:54:02 +08:00
Andrew Nicols
4c34089889 MDL-47987 mod_forum: Users subscribe to discussions not forums
Correct language string which describes users subscribing to a discussion,
and use it when subscribing on post.
2014-10-31 07:51:48 +08:00
Andrew Nicols
4238983e2a MDL-47107 mod_forum Optimise forum subscription checks
Supply a coursemodule where relevant to the forum subscription checks.
2014-09-05 15:06:15 +08:00
Andrew Nicols
ebfb73db7b MDL-1626 mod_forum: Update user interface to reflect per-discussion subscriptions
AMOS BEGIN
  MOV [forcessubscribe,mod_forum],[forcesubscribed,mod_forum]
AMOS END
2014-06-24 12:16:34 +08:00
Andrew Nicols
e3bbfb52c4 MDL-1626 mod_forum: Add functions to change user discussion subscription state 2014-06-24 12:16:34 +08:00
Andrew Nicols
59075a4349 MDL-1626 mod_forum: Move subscription management to a separate class 2014-06-24 12:16:33 +08:00
Eloy Lafuente (stronk7)
6a586f0036 Merge branch '44157-27' of git://github.com/samhemelryk/moodle 2014-02-18 00:51:33 +01:00
Sam Hemelryk
01030f1be6 MDL-44157 mod_forum: unified @package use 2014-02-18 11:15:10 +13:00
Dan Poltawski
de2770501e MDL-40062 mod_forum: subscription events
Events for forum mail subscriptions

* subscription_created
* subscription_deleted
* subscribers_viewed
2014-02-17 14:05:54 +08:00
Damyon Wiese
74df2951d1 Revert "MDL-39876 Change get_record('course') calls to get_course"
This reverts commit ab7632b74c.
2013-08-21 13:42:30 +08:00
sam marshall
ab7632b74c MDL-39876 Change get_record('course') calls to get_course 2013-08-15 11:31:20 +01:00
Gilles-Philippe Leblanc
4a913724d0 MDL-32125 mod_forum: Updating subscription mode not reflecting subscribers 2013-02-28 11:33:51 -05:00
Matt Oquist
e9d87d90cf MDL-36958 Forum: Replaced hard-coded numbers with proper defines 2012-12-18 17:26:50 +08:00
Ankit Agarwal
bf0f06b1be MDL-34471 libraries: Replace all uses of get_context_instance() with respective context_XXXX::instance() method 2012-08-02 15:37:38 +08:00
Charles Fulton
4cd5ae4f00 MDL-33194 forum: correct number of parameters for get_record() 2012-05-22 11:33:21 -07:00
Petr Skoda
cdbea7eed1 MDL-31607 use full course object for require_login() if already available
This eliminates 1 db query.
2012-04-22 17:41:47 +02:00
Eloy Lafuente (stronk7)
ecabd5b039 MDL-31428 forum: prevent some warnings with debug enabled 2012-01-31 00:22:32 +01:00
Petr Skoda
72650054f4 MDL-26833 send forum notifications to active enrolled users only 2011-03-16 23:26:00 +01:00
David Mudrak
6f7d65c724 MDL-24561 forum subscription checks sesskey
The only case when sesskey is not available is when we came to
subscribe.php from a link in email. In that case, we display a
confirmation page that redirects back providing the sesskey.
All other links to subscribe.php are fixed now so they provide sesskey
as a parameter.
I also polished $mode parameter handling a bit because the check
against empty string was not correct as the value is cast to PARAM_INT.
2011-01-05 13:01:46 +01:00
David Mudrak
d1571da6c8 MDL-25068 forum: fixed error string usage
The string [cannotsubscribe,mod_forum] is supposed to be used for group
membership check only. I have fixed the two other usages of the string.
Note that the condition if (forum_subscribe()) was useless as the
function return true values only now after $DB conversion.
2010-12-07 12:34:35 +00:00
David Mudrak
9a3adb2032 NOMDL forum: fixed the string wording to match the current code condition
Previous string was used together with the legacy:guest capability.
However, the current code checks is_enrolled() instead. This led to a
weird situation when non-enrolled admin or manager could not subscribe
to a forum and the error message was completely confusing for them.
2010-12-07 12:34:11 +00:00
David Mudrak
99eb51d9e4 MDL-22114 forum: fixed PAGE url param set
I am pretty sure Sam overlooked this is in the commit afef965e
2010-12-07 12:33:24 +00:00
Sam Hemelryk
afef965e28 mod-forum MDL-22114 Enhanced navigation options for forum in regards to subscription. 2010-04-21 08:05:03 +00:00
Petr Skoda
4f0c2d0009 MDL-21655 big scary enrolment and roles improvements - see tacker for list of changes, includes other minor fixes too 2010-03-31 07:41:31 +00:00
Petr Skoda
a685593466 MDL-21233 moodle_url improvemewnts, code simplification, more diagnostics; fixed several regressions 2010-01-16 15:39:56 +00:00
Petr Skoda
2f67a9b3a5 MDL-20700 whitespace terror returns yet again 2009-12-16 22:22:37 +00:00
Sam Hemelryk
8f685009b3 forum MDL-21086 cleaned up boilderplates and php doc packages 2009-12-10 03:11:18 +00:00
Petr Skoda
1adbd2c350 MDL-20700 coding style cleanup - cvs keywords removed, closign php tag removed, trailing whitespace cleanup 2009-11-01 14:55:15 +00:00
samhemelryk
cd4e6b1769 mod-forum MDL-19808 Added set_url calls, replaced deprecated functions 2009-09-24 06:41:04 +00:00
samhemelryk
15ca5e5e0d forum MDL-19808 Upgraded print_header and build_navigation calls to OUTPUT/PAGE equivilants 2009-09-04 05:50:21 +00:00
nicolasconnault
59e28d8f5d MDL-19808 upgraded calls to print_table, print_single_button, print_user_picture, print_container* and notice_yesno 2009-08-20 08:44:35 +00:00
nicolasconnault
396fb912ff MDL-19808 Converted all print_footer() calls 2009-08-06 14:14:09 +00:00
skodak
93f66983cc MDL-17773 new get_login_url() function - fixes missing httpslogin tweaks 2009-01-02 22:56:48 +00:00
dongsheng
dde78cb8f2 MDL-14129, remove error() in forum mod. 2008-07-21 08:03:42 +00:00
nicolasconnault
4e44535526 MDL-15108 Upgrade finished, preliminary tests successful. Please continue testing. 2008-06-05 20:16:09 +00:00
skodak
35987665f4 MDL-14617 removed some legacy group code 2008-05-01 22:30:28 +00:00
skodak
90f4745c22 MDL-14113 patch for multiple issues - see tracker for subtasks; merged from MOODLE_19_STABLE 2008-04-13 19:15:02 +00:00
dongsheng
5a2a53316f MDL-14129, remove all the other error() call 2008-04-04 02:54:20 +00:00
scyrma
d417533252 Fix for par of the missing strings, as reported in MDL-12294 2007-11-26 04:10:08 +00:00
dwoolhead
01cbbbd70a MDL-11979 Forum subscriptions loop hole allowing users to subscribe to forums they should not have access to. 2007-11-16 16:31:00 +00:00
sam_marshall
52ca1e737e MDL-12055 Tweaked forum subscribe 'continue' address 2007-11-07 17:33:12 +00:00
sam_marshall
93e898eb4d MDL-12055 Tweaked forum subscribe 'continue' address 2007-11-07 17:04:48 +00:00