2108 solutions found
Page 96 of 106votes
I'm creating a moodle site for school students with couple courses. When they start the course, I want to have a page like terms of agreement with a che...
votes
I am trying to install moodle on my server. I did unpack moodle package in public html folder. This moodle folder has `755` access rights set. Then I create...
votes
I am trying to create an authentication plugin, but I am having problems when the user does not exist in the moodle database. Therefore I am trying to find a wa...
votes
I'm new to moodle. I need your suggestions to create plugin which will add a custom field on Add/edit courses page and will also store the input value in `m...
votes
I just want to know is it ok to add new tables to the `moodle` database or should I create a new database for that? I need a table to save a unique id and a tok...
votes
I am trying to trigger an ajax call on change of a dropdown menu(at client_script.php). The ajax call will send some values to server_script.php and it will cha...
votes
### What is this? This is a collection of questions that come up now and then about syntax in PHP. This is also a Community Wiki, so everyone is invited to p...
votes
Is there an easy way to delete an element from an array using PHP, such that `foreach ($array)` no longer includes that element? I thought that setting it to...
votes
If I have a YouTube video URL, is there any way to use PHP and cURL to get the associated thumbnail from the YouTube API?
votes
Consider: $a = 'How are you?'; if ($a contains 'are') echo 'true'; Suppose I have the code above, what is the...
votes
How can one parse HTML/XML and extract information from it?
votes
Let me prefix this by saying that I know what `foreach` is, does and how to use it. This question concerns how it works under the bonnet, and I don't want a...
votes
In PHP 5, what is the difference between using `self` and `$this`? When is each appropriate?
votes
I have checked my PHP ini file (`php.ini`) and `display_errors` is set and also error reporting is `E_ALL`. I have restarted my Apache webserver. I have even...
votes
I have an HTML (not XHTML) document that renders fine in Firefox 3 and IE 7. It uses fairly basic CSS to style it and renders fine in HTML. I'm now afte...
votes
How can I write two functions that would take a string and return if it starts with the specified character/string or ends with it? For example: $str...
votes
In PHP: - When should I use `require` vs. `include`? - When should I use `require_once` vs. `include_once`?
votes
How can I sort this array by the value of the "order" key? Even though the values are currently sequential, they will not always be. Array...
votes
I'm running a PHP script and continue to receive errors like: > Notice: Undefined variable: my_variable_name in C:\wamp\www\mypath\index.php on line 1...
votes
I have an array: `array( 4 => 'apple', 7 => 'orange', 13 => 'plum' )` I would like to get the first element of this arr...