problem about moodle-Collection of common programming errors


  • Ray
    c# client xml-rpc moodle
    I am using the CookComputing XML-RPC Library in an attempt to build a C# console client in order to execute API methods on Moodle (an open-source Learning management system). The server is using ZEND XML-RPC.When I run the code, I get a TypeLoadException was Unhandled, referring to this line: System.Object myResults = proxy.moodle_user_get_user_by_id(myUserIds);”Inheritance security rules violated while overriding member: ‘CookComputing.XmlRpc.XmlRpcFaultException.GetObjectData(System.Runtime.Se

  • hakre
    php soap soap-client moodle
    I am having difficulty getting started with interfacing my PHP script to Moodle 2.0 over the SOAP Web Service provided. Not knowing much about SOAP, I figured I would simply connect and go from there. However, I can’t even get connected…$soap=new SoapClient(‘http://mymoodleserver/webservice/xmlrpc/server.php?wstoken=asdfasdfasdfasdfasdf’,array(‘trace’=>1,’exceptions’=>true,’cache_wsdl’=>WSDL_CACHE_NONE) );This returns:Fatal error: Uncaught SoapFault exception: [WSDL] SOAP-ERROR: Par

  • dglickler
    tinymce loading moodle filepicker
    I’ve created a fresh install of Moodle 2.5.I installed successfully, I thought. I have not customized the theme, so it can NOT be theme-based.TinyMCE’s file picker is not loading…whether trying to upload a file or creating/editing a course under the Course summary files section…all I get is the “Loader” star. I did some research and found no solutions that worked. Quite a few said “custom themes,” but I have no custom themes yet. Now, in checking the console, I got this:Uncaught SyntaxError:

  • Dozent
    php json moodle
    I’m trying to get json data by calling moodle url:https://<moodledomain>/login/token.php?username=test1&password=Test1&service=moodle_mobile_appthe response format of moodle system is like this:{“token”:”a2063623aa3244a19101e28644ad3004″}The result I tried to process with PHP:if ( isset($_POST[‘username’]) && isset($_POST[‘password’]) ){// test1 Test1// request for a ‘token’ via moodle url$json_url = “https://<moodledomain>/login/token.php?usern

  • Brad
    iis6 php5 fastcgi isapi moodle
    I am working with Moodle 1.9 running on Windows Server 2003, IIS 6. I am trying to switch from PHP’s ISAPI extension to FastCGI, hoping for a speed improvement.I installed FastCGI for IIS 6 just fine, and configured it for PHP. It works, and in fact most of Moodle works great. The only thing that doesn’t, is the home page. When running as FastCGI, I get this error:PHP Notice: Undefined index: description in C:\Inetpub\wwwroot\moodle\lib\magpie\rss_parse.inc on line 402So I thought, “Hmmm,

  • hakre
    php mamp moodle iconv
    I have downloaded Moodle and extracted zip file. then i have placed this moodle in MAMP/htdocs. Now i am browsing from localhost:8888/moodle, i am geting these following error. “Broken iconv PHP extension detected, installation can not continue.”. How can i fix it?

  • markus
    php apache moodle
    I have Moodle 2.3.3+ and after I press “continue” in “extension check page” in the installation the server will stop and when i try to access any domain on the server this message will come up:The connection was resetand after 3-5 minutes the server will response again and the installation will continue to the “admin registration” and when i press “submit” the server will crash again without saving the admin information.Server Specifications:Dedicated Server Intel® CoreT i7-920 Quadcore RAM 24

  • Christos312
    php html moodle
    I am trying to create a custom login page for Moodle. Everything works perfect but I need to also add the “Remember username” option.The problem with that is in the core files (see below) they use some variables to remember and echo the username. How can I do that in my login.php file? When I try to echo p($frm->username) I get an error that is Undefined. And the reason is obvious. My question is, is there a way to include their index.php file in my file and use the variables or functions they h

  • Gregory-Turtle
    php mysql sql moodle
    I am porting a Moodle 1.0 module to version 2.0. While checking for errors in several PHP files, I ran into an error message for a query, but there was no indication of what the error was. Here is the query:global $DB; //required global variable$vms = $DB->get_records_sql(‘SELECT DISTINCT vm.*, uva.assignment_id, gm.groupid,CASE WHEN gm.groupid IS NULL THEN uva.user_id ELSE NULL END user_idFROM {mdl_vMoodle_Virtual_Machine} vm INNER JOIN {mdl_vMoodle_UVA} uva ON vm.id = uva.vm_id LEFT JOIN {m

  • Zxaos
    plugins block moodle
    I have a moodle block plugin where I’m trying to include javascript in the page.No matter how I try, the javascript called by the js_init_call always throws an error instead of running I’ve tried passing a full array to js_init_call, and I’ve tried the shorthand form that assumes the file is called module.jsIf the javascript file doesn’t exist, I get a moodle error complaining about the missing file. If it does exist, I get a javascript error as above. What am I doing wrong?block_foo.php:<?ph

  • thibaultCha
    moodle
    I’m doing an update for a Moodle plugin. Basically all I want to do is to add some fields to an existing table in database.Here’s my upgrade.php built from the XMLDB editor:function xmldb_qtype_myqtype_upgrade($oldversion = 0) { global $DB; $dbman = $DB->get_manager();$result = true;if ($oldversion < 2013031601) {// Define table solib to be created$table = new xmldb_table(‘solib’);// Adding fields to table solib$table->add_field(‘id’, XMLDB_TYPE_INTEGER, ’10’, null, XMLDB_NOTNULL, XMLDB

  • Sven
    php moodle zend-guard
    I’m receiving this error on my hosting provider account. I know it is a php related error that doesn’t allow me to reach my moodle site. I have access to the php.ini but i haven’t been able to make php to work properly just with moodle 2.4.1. It works fine with a wordpress install.