Moodle 3.0, 3.2: Format the Single Record View in a Database
Applies to: Moodle 3.0, 3.2
A database in Moodle allows an instructor and students to build, display and search a bank of record entries about any topic.
Entries can be viewed in a list or by viewing each one individually in the Single view. By default, the Single view is difficult to read. You can modify the template for the Single view to make it easier to read.
Find the Database you want to modify and click the Database link.
Click the Templates tab. A new sub-set of tabs appear.
Click the Single template tab.
Look at the Single template textbox:
Notice there is a table with your field names on the left and the names repeated between double brackets on the right. The bracketed text is special code; you should not modify this text. The names on the left, however, are just plain text, and you can make changes to this text.
Change the text labels to make them more readable:
Add spaces between words.
Add more text where needed.
Bold text as desired. Example:
Add the student’s name to the Single view, if desired:
Click in the Single template textbox just to the left of the table. You should have a long blinking cursor to the left of the table.
Press Enter or Return on your keyboard. The entire table moves down a row.
Click in the textbox just above the table. Your cursor is in the middle of the row above the table.
Type ##user##. This is code that will display the name of the student who submitted the entry.