Moodle Docs: Frequently Asked Questions (FAQ)

# Ofte Stilte Spørsmål (OSS)

Denne siden inneholder svar på noen av de oftest stilte spørsmålene av personer som installerer Moodle. Dersom du har fulgt instruksjonene for installasjon men har fortsatt problemer, er dette sannsynligvis den beste siden å lete etter løsninger på.

Dersom du ikke finner svaret ditt her, prøv kurset Using Moodle hos moodle.org. Start med å søke i foraene med noen få nøkkelord, i tilfelle noen allerede har diskutert ditt problem. Dersom du ikke finner svar kan du prøve å sende egne spørsmål i forumet som handler om det aktuelle emnet - noen er som regel i stand til å hjelpe deg.

Dersom du har forsøkt flere foreslåtte løsninger som ikke har løst problemet og du kjørere bak en brannmur kan det være nødvendig å konfigurere brannmuren på nytt for å forsikre at den ikke blokkerer en nødvendig funksjon eller nødvendig kommunikasjon. Brannmurer forårsaker svært sjelden problemer for Moodle, men forårsaker noen ganger redusert funksjonalitet på grunn av feil konfigurering av brannmuren.

Klikk på et spørsmål i denne listen for å hoppe til ønsket svar nedenfor:

Uansett når jeg prøver å få tilgang til en fil jeg har lastet opp får jeg feilmeldingen "Filen ikke funnet".

PHP - er det installert og hvilken versjon har jeg?

Hvorfor er alle sidene mine tomme?

Mine sider viser kritiske feil som: call to undefined function: get_string()

Hvorfor får jeg stadig feilmeldinger som "headers already sent"?

Jeg får stadig denne feilen: Failed opening required '/web/moodle/lib/setup.php'

All tekst jeg legger ut med apostrof (') eller hermetegn (") gir feil eller kommer med en skråstrek i tillegg.

Jeg får gjentatte feilmeldinger om session_start.

Når jeg går til Administrasjonssiden (Admin) blir jeg bedt om å gjøre "dirroot" blank!

Jeg logger inn, men lenken "Logg inn" endrer seg ikke. Jeg er logget inn og kan navigere fritt.

Jeg får feilmeldinger når jeg prøver å legge ut en ressurs.

I starten av setup-prosessen ble jeg aldri spurt om å opprette en administratorkonto! (Admin)

Jeg kan ikke logge inn i det hele tatt - Jeg blir bare stående fast på skjermbildet for innlogging.

Hvordan tar jeg sikkerhetskopi av mitt Moodlenettsted?

Hvorfor viser ikke Moodle på min side dato og klokkeslett riktig?

E-postkopier blir ikke sendt fra mine fora.

### Uansett når jeg prøver å få tilgang til en fil jeg har lastet opp får jeg feilmeldingen "Filen ikke funnet".

For eksempel: Not Found: The requested URL /moodle/file.php/2/myfile.jpg was not found on this server.

Your web server needs to be configured to allow the part of the URL after a script name to be passed directly to the script. This is usually enabled in Apache 1, but is usually disabled by default in Apache 2. To turn it on, add this line to your httpd.conf, or to a .htaccess file in your local directory (see the Install documentation for more details):

AcceptPathInfo on

Note, this will ONLY work for Apache versions 2.x.

If you are not using Apache 2 and you still have this problem (unlikely) then you can switch Moodle to use an alternative method. The disadvantages are a slight loss of performance for your users and you won't be able to use relative links within HTML resources.

To use this alternative method: login as Admin, go into the "Configure Variables" page and change the setting for "slasharguments". You should now be able to access your uploaded files.

### PHP - er det installert og hvilken versjon har jeg?

Make a new file on your web site called info.php, containing the following text, and call it from your browser:

<?PHP phpinfo() ?>

If nothing happens then you don't have PHP installed. See the installation docs for some information about where to download it for your computer.

### Hvorfor er alle sidene mine tomme?

Check the dirroot variable in config.php. You must use complete, absolute pathnames, eg:

$CFG->dirroot = "d:\inetpub\sites\www.yoursite.com\web\moodle";

Redhat Linux platform please see: Redhat Linux

### Mine sider viser kritiske feil som: call to undefined function: get_string()

If you see errors like:

Parse error: parse error, unexpected T_VARIABLE in c:\program files\easyphp\www\moodle\config.php on line 94
Fatal error: Call to undefined function: get_string() in c:\program files\easyphp\www\moodle\mod\resource\lib.php on line 11

then it's likely you have left out a semi-colon or ending quote from a line in config.php (previous to line 94).

Another reason could be that you have opened config.php in a program like Word to edit it, and saved it as a HTML web page, instead of a proper text file.

### Hvorfor får jeg stadig feilmeldinger som "headers already sent"?

If you see errors like this:

Warning: Cannot add header information - headers already sent by (output started at /webs/moodle/config.php:87) in /webs/moodle/lib/moodlelib.php on line 1322

Warning: Cannot add header information - headers already sent by (output started at /webs/moodle/config.php:87) in /webs/moodle/lib/moodlelib.php on line 1323

Warning: Cannot add header information - headers already sent by (output started at /webs/moodle/config.php:87) in /webs/moodle/login/index.php on line 54

You have blank lines or spaces after the final ?> in your config.php file. Sometimes text editors add these - for example Notepad on Windows - so you may have to try a different text editor to remove these spaces or blank lines completely.

### Jeg får stadig denne feilen: Failed opening required '/web/moodle/lib/setup.php'

In your config.php, the setting that you use for the dirroot variable must be the complete path from the root of your server's hard drive.

Sometimes people only use the path from their home directory, or relative to the root of the web server directory.

### All tekst jeg legger ut med apostrof (') eller hermetegn (") gir feil eller kommer med en skråstrek i tillegg.

Problems caused by apostrophes are caused by incorrect "magic quotes" settings. Moodle requires the following settings (which are usually the default):

magic_quotes_gpc = On
magic_quotes_runtime = Off

See the section on webserver configuration in the Installation docs for more details.

### Jeg får gjentatte feilmeldinger om session_start.

If you see errors like this:

Warning: session_start() [function.session-start]: open(/tmp\sess_d40f380d37d431fc1516e9a895ad9ce0, O_RDWR) failed: No such file or directory (2) in G:\web\moodle\lib\setup.php on line 123

Warning: session_start() [function.session-start]: open(/tmp\sess_d40f380d37d431fc1516e9a895ad9ce0, O_RDWR) failed: No such file or directory (2) in G:\web\moodle\lib\setup.php on line 123

Warning: session_start() [function.session-start]: Cannot send session cache limiter - headers already sent (output started at G:\web\moodle\lib\setup.php:1) in G:\web\moodle\lib\setup.php on line 123

... these are all related to the fact that PHP is failing to save "session" files on your hard disk (in a directory called /tmp). Usually the reason is that you don't HAVE a directory called /tmp on your computer. This is usually the case with Windows installations.

The solution is to fix the PHP setting for this path to point to a real directory. You can do this in your php.ini file:

session.save_path = C:\temp

or otherwise in a .htaccess file in your main moodle directory:

php_value session.save_path "/home/moodle/sessions"

### Når jeg går til Administrasjonssiden (Admin) blir jeg bedt om å gjøre "dirroot" blank!

If you see errors like this in Moodle 1.0.9:

Please fix your settings in config.php: You have: $CFG->dirroot = "/home/users/fred/public_html/moodle"; but it should be: $CFG->dirroot = "";

then you have encountered a small bug that occurs on some servers. The problem is with the error-checking mechanism, not with your actual path. To fix it, find this line (line 66) in the file admin/index.php:

if ($dirroot != $CFG->dirroot) {

and change it to this:

if (!empty($dirroot) and $dirroot != $CFG->dirroot) {

### Jeg logger inn, men lenken "Logg inn" endrer seg ikke. Jeg er logget inn og kan navigere fritt.

Make sure the URL in your $CFG->wwwroot setting is exactly the same as the one you are actually using to access the site.

### Jeg får feilmeldinger når jeg prøver å legge ut en ressurs.

Assuming you are using Apache, then it's quite likely that your setting in config.php for $CFG->wwwroot is different from the actual URL you are using to access the site. Also try turning off "secureforms" in the admin settings.

### I starten av setup-prosessen ble jeg aldri spurt om å opprette en administratorkonto! (Admin)

This is a known bug in versions of Moodle up to 1.0.9, now fixed in the main code and version 1.1.

It doesn't affect all people, it only occurs when the person installing Moodle has a cookie in their browser from another program on the same site, called "user", "admin", or "teacher".

Quick fixes include deleting those cookies from your browser before installing, using a different browser, or editing the file moodle/admin/user.php to insert these lines near the top:

unset($user);
unset($admin);
unset($teacher);

After performing any of these fixes it might be a good idea to drop all the tables in your database and re-install again from scratch.

### Jeg kan ikke logge inn i det hele tatt - Jeg blir bare stående fast på skjermbildet for innlogging.

The most common cause for this is that your own computer (not your Moodle server) has a firewall that is stripping referrer information from the browser. Here are some instructions for fixing Norton firewall products.

The server admin can also fix this for everyone by editing the Moodle configuration page and changing the variable "secureforms" to "No".

Another possible cause of this problem is that sessions are not configured properly on the server. You can test this by calling the script http://yourserver/moodle/lib/session-test.php.

### Hvordan tar jeg sikkerhetskopi av mitt Moodlenettsted?

There are two main things you need to make a copy of: the database and the uploaded files. The Moodle scripts themselves are less important, since you can always download a fresh copy if you have to.

There are many ways to do such backups. Here is an outline of a little script you can run on Unix to backup the database (it works well to have such a script run daily via a cron task

cd /my/backup/directory

mv moodle-database.sql.gz moodle-database-old.sql.gz

mysqldump -h example.com -u myusername --password=mypassword -C -Q -e -a mydatabasename > moodle-database.sql

gzip moodle-database.sql

For the files, you can use rsync regularly to copy only the changed files to another host:

rsync -auvtz --delete -e ssh mysshusername@example.com:/my/server/directory /my/backup/directory/

### Hvorfor viser ikke Moodle på min side dato og klokkeslett riktig?

Each language requires a specific language code (called a locale code) to allow dates to be displayed correctly. The language packs contain default standard codes, but sometimes these don't work on Windows servers.

You can find the correct locale codes for Windows on these two pages: Language codes and Country/region codes.(eg "esp_esp" for spanish)

These new locale codes can be entered on the Admin -> Configure -> Variables page, where they override the ones in the currently chosen language pack.

### E-postkopier blir ikke sendt fra mine fora.

You must set up cron properly if you want Moodle to send out automatic email from forums, journals, assignments etc. This same process also performs a number of clean-up tasks such as deleting old unconfirmed users, unenrolling old students and so on.

Basically, you need to set up a process to regularly call the script http://yoursite/admin/cron.php. Please see the section on cron in the Installation documentation.

Tip: Try the default setting in Moodle variables page. Leave the smtphost blank. This will be acceptable for the majority of users.

Foreslå et nytt OSS (inkluder svaret!)

Takk til John Eyre for hjelp til vedlikehold av denne OSS'en.

Dokumentasjon om M oodle

Versjon: $Id: faq.html,v 1.6 2003/03/30 13:54:28 moodler Exp $