moodle

How do I delete course enrolments in moodle in bulk?

隐身守侯 提交于 2019-12-25 04:08:10
问题 Moodle has a built in per course reset ability. I want to reset all my courses. 回答1: Sorry to bring this old post back but after a long struggle I finally got that code to work. I've tested it on a Moodle 1.9.7 enviroment <?php require('../config.php'); require_once('reset_form.php'); $courseids = array(8,9,11); foreach ($courseids as &$value) { $data->MAX_FILE_SIZE = 8097152; $data->reset_start_date = 1251781200; $data->reset_events = 1; $data->reset_logs = 1; $data->reset_notes = 1; $data-

mutation observer production infinite loop

99封情书 提交于 2019-12-24 17:06:20
问题 I'm writing a function using the mutation observer with jQuery to register changes to the DOM, specifically when a new node is added so i can change its content: $("SELeCTOR GOOD" ).click(function(){ var targetNode = $(this).find('.content').get(0); var config = { attributes: true, childList: true, subtree: true, attributeOldValue: true }; // Callback function to execute when mutations are observed var callback = function(mutationsList) { for(var mutation of mutationsList) { if (mutation.type

Check if a Moodle user is online

走远了吗. 提交于 2019-12-24 16:53:17
问题 I need to know if a user is on-line at Moodle, there is a Moodle block for it, but actually it just check if the user had an activity on Moodle in the last X minutes, but in my case that is not useful. There is anyway to know it? 回答1: As the other answerers say, it isn't possible to see if a user is currently online. As you mentioned, the online users block checks the value of mdl_user.lastaccess . It's probably the best option but even then it depends on the user accessing or refreshing a

Moodle Database Overload Error

[亡魂溺海] 提交于 2019-12-24 08:28:47
问题 The system was running fine, but all of a sudden got this error 'Database connection failed', what might be the possible issues, how can I fix this error forever. Thank you. System Information: Ubuntu 16.04.3 x64 2 GB Memory / 50 GB Disk I checked with 'df -h' in the terminal, I did error log check: 2018-07-31T10:10:04.751870Z 0 [Note] /usr/sbin/mysqld: Shutdown complete 2018-07-31T10:10:34.438715Z 0 [Warning] Changed limits: max_open_files: 1024 (requested 5000) 2018-07-31T10:10:34.438807Z 0

Share user login/session between cakephp and moodle

一曲冷凌霜 提交于 2019-12-24 06:39:04
问题 I have a website already running made with CakePHP, which has its own login system using the Auth component. Now I'm going to create another website using moodle, hosted in the same server. Is there any way to share the user session between those 2 websites? For example, if a user logs into the moodle website and clicks a link to a page of the other website, he is not asked to log in again, since the system recognises that he is already logged in. I guess that one thing to do would be to tell

Netbeans 8 and xdebug very very slow

烂漫一生 提交于 2019-12-23 19:26:50
问题 I've read other posts about this issue, but I can't get a satisfactory performance with xdebug 2.2.5 and netbeans 8.0.1 on a local web server (apache 2.4.9, php 5.5.12 on windows 7). Some pages load in over 40 seconds, worse than the remote server performances. This is the xdebug section on my php.ini after the recommandations taken from some other post: xdebug.remote_enable=1 xdebug.remote_handler="dbgp" xdebug.remote_mode=req xdebug.remote_host=127.0.0.1 xdebug.remote_port=9000 xdebug

How to store a file in Moodle so that it is accessible for an external application?

女生的网名这么多〃 提交于 2019-12-21 06:28:18
问题 I need to store a file in Moodle. This is not really a problem, it is explained here. The problem is that this file has to be accessible for everyone. Hence, there has to be a URL, e.g. www.mymoodlesite.com/temp/myfile.txt or the like, which one can enter in ones browser and access the file. I thought of copying the file into the moodledata/temp folder, but then I do not have a URL in order to access the file.. Thanks for your help in advance! 回答1: Finally I could solve my problem :-) I used

How to store a file in Moodle so that it is accessible for an external application?

冷暖自知 提交于 2019-12-21 06:28:06
问题 I need to store a file in Moodle. This is not really a problem, it is explained here. The problem is that this file has to be accessible for everyone. Hence, there has to be a URL, e.g. www.mymoodlesite.com/temp/myfile.txt or the like, which one can enter in ones browser and access the file. I thought of copying the file into the moodledata/temp folder, but then I do not have a URL in order to access the file.. Thanks for your help in advance! 回答1: Finally I could solve my problem :-) I used

is there any API exists for Moodle? [closed]

心不动则不痛 提交于 2019-12-20 14:00:40
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed last year . I want to create a customized front end for Moodle. Does anyone know that from where I can get API for this? or any other help? 回答1: [Edit: I have written on, moodle theme modification which we did at http://www.iank.it/category/e-learning/ for http://www.edupristine.com/ca ] It will be very tiresome to create a

is there any API exists for Moodle? [closed]

放肆的年华 提交于 2019-12-20 14:00:02
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed last year . I want to create a customized front end for Moodle. Does anyone know that from where I can get API for this? or any other help? 回答1: [Edit: I have written on, moodle theme modification which we did at http://www.iank.it/category/e-learning/ for http://www.edupristine.com/ca ] It will be very tiresome to create a