2015-02-06 67 views
0

我想定製Moodle登錄頁面。這就是爲什麼我想將「用戶名」這樣的關鍵字更改爲「uid」以及將關鍵字「password」更改爲「Userpassword」的原因。定製Moodle登錄頁面

我使用的是Moodle版本:2.7,主題:乾淨。

建議我對這些關鍵字進行更改。

回答

5

您可以通過菜單更改語言字符串

網站管理 - >語言 - >語言定製 - >選擇語言 - >搜索字符串

在幕後,這將創建一個本地版本moodledata/lang/

如:moodledata/lang/en_local/moodle.php

這比修改核心代碼更好。

或者您可以直接創建上述文件並添加需要修改的字符串,例如:

<?php 

// This file is part of Moodle - http://moodle.org/ 
// 
// Moodle 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 3 of the License, or 
// (at your option) any later version. 
// 
// Moodle 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. 
// 
// You should have received a copy of the GNU General Public License 
// along with Moodle. If not, see <http://www.gnu.org/licenses/>. 

/** 
* Local language pack from http://yourwebsite.com 
* 
* @package core 
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later 
*/ 

defined('MOODLE_INTERNAL') || die(); 

$string['password'] = 'Userpassword'; 
$string['username'] = 'uid'; 
+0

謝謝你的回覆。 – preethi 2015-02-06 06:30:15

+0

我已添加到文件中,但如何查看更改.i無法查看任何更改。 – preethi 2015-02-06 06:31:13

+2

網站管理員>開發人員>清除所有緩存。這應該加載你所做的改變(如果你通過系統菜單改變語言字符串,它會自動完成) – davosmith 2015-02-06 07:10:26