สวัสดีครับ ..... อาจารย์ทุกท่าน...
ผมใช้ Moodle 1.4 และมีโดเมนเนมชื่อ www.supradit.com ซึ่งติดตั้ง PHP NUKE 7.0 มีเนื้อหาเกี่ยวกับวิชางานช่าง แต่อยากใช้ Moodle มาทำในส่วนของแบบทดสอบและแบบฝึกหัดต่าง ๆ ซึ่งผมได้ดำเนินการดังนี้ครับ
1. ขอ SubDomain ชื่อ http://classroom.supradit.com
2. Upload ไฟล์ต่าง ๆ ขึ้นไปไว้ที่ SubDomain
3. สร้าง Database ชื่อ classroom ที่ SubDomain ด้วย phpmyadmin
4. แก้ไฟล์ config.php ดังนี้
<?PHP // $Id$
///////////////////////////////////////////////////////////////////////////
// //
// Moodle configuration file //
// //
// This file should be renamed "config.php" in the top-level directory //
// //
///////////////////////////////////////////////////////////////////////////
// //
// NOTICE OF COPYRIGHT //
// //
// Moodle - Modular Object-Oriented Dynamic Learning Environment //
// http://moodle.org //
// //
// Copyright (C) 1999-2004 Martin Dougiamas http://dougiamas.com //
// //
// This program is free software; you can redistribute it and/or modify //
// it under the terms of the GNU General Public License as published by //
// the Free Software Foundation; either version 2 of the License, or //
// (at your option) any later version. //
// //
// This program is distributed in the hope that it will be useful, //
// but WITHOUT ANY WARRANTY; without even the implied warranty of //
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the //
// GNU General Public License for more details: //
// //
// http://www.gnu.org/copyleft/gpl.html //
// //
///////////////////////////////////////////////////////////////////////////
unset($CFG); // Ignore this line
//=========================================================================
// 1. DATABASE SETUP
//=========================================================================
// First, you need to configure the database where all Moodle data //
// will be stored. This database must already have been created //
// and a username/password created to access it. //
// //
// mysql - the prefix is optional, but useful when installing //
// into databases that already contain tables. //
//
// postgres7 - the prefix is REQUIRED, regardless of whether the //
// database already contains tables. //
// //
// A special case exists when using PostgreSQL databases via sockets. //
// Define dbhost as follows, leaving dbname, dbuser, dbpass BLANK!: //
// $CFG->dbhost = " user='muser' password='mpass' dbname='mdata'"; //
//
$CFG->dbtype = 'mysql'; // mysql or postgres7 (for now)
$CFG->dbhost = 'localhost'; // eg localhost or db.isp.com
$CFG->dbname = 'classroom'; // database name, eg moodle
$CFG->dbuser = 'supradit'; // your database username
$CFG->dbpass = '987654321'; // your database password
$CFG->prefix = 'mdl_'; // Prefix to use for all table names
$CFG->dbpersist = false; // Should database connections be reused?
// "false" is the most stable setting
// "true" can improve performance sometimes