Permalink
Browse files

More language fixes

  • Loading branch information...
1 parent 6821bec commit 3db1919bafb5aa1735e845f5ba0b9495dcd6e939 martin committed Aug 12, 2002
View
@@ -34,7 +34,6 @@
$string[nameteacher] = "Teacher forum";
$string[nodiscussions] = "There are no discussion topics yet in this forum";
$string[noposts] = "No posts";
-$string[numwords] = "\$a words";
$string[numposts] = "\$a posts";
$string[olderdiscussions] = "Older discussions";
$string[parentofthispost] = "Parent of this post";
View
@@ -6,6 +6,23 @@
#------------------------------------------------------------
+$string[alwaysopen] = "Always open";
+$string[blankentry] = "Blank entry";
+$string[daysavailable] = "Days available";
+$string[editingends] = "Editing period ends";
+$string[editingended] = "Editing period has ended";
+$string[journalname] = "Journal name";
+$string[journalquestion] = "Journal question";
+$string[journalrating1] = "Not satisfactory";
+$string[journalrating2] = "Satisfactory";
+$string[journalrating3] = "Outstanding";
$string[noentry] = "No entry";
+$string[notopenuntil] = "This journal won't be open until";
+$string[notstarted] = "You have not started this journal yet";
+$string[noratinggiven] = "No rating given";
+$string[overallrating] = "Overall rating";
+$string[rate] = "Rate";
+$string[startoredit] = "Start or edit my journal entry";
+$string[viewallentries] = "View all journal entries";
?>
View
@@ -100,6 +100,7 @@
$string[enteremailaddress] = "Enter in your email address to reset your
password and have the new password sent to you via email.";
$string[error] = "Error";
+$string[feedback] = "Feedback";
$string[files] = "Files";
$string[firstname] = "First name";
$string[firsttime] = "Is this your first time here?";
@@ -125,6 +126,7 @@
$string[invalidlogin] = "Invalid login, please try again";
$string[invalidemail] = "Invalid email address";
$string[lastaccess] = "Last access";
+$string[lastedited] = "Last edited";
$string[lastmodified] = "Last modified";
$string[lastname] = "Last name";
$string[latestnews] = "Latest news";
@@ -222,6 +224,10 @@
$string[nothingnew] = "Nothing new since your last login";
$string[now] = "now";
$string[numberweeks] = "Number of weeks/topics";
+$string[numdays] = "\$a days";
+$string[numweeks] = "\$a weeks";
+$string[numyears] = "\$a years";
+$string[numwords] = "\$a words";
$string[ok] = "OK";
$string[opentoguests] = "Open to guests?";
$string[optional] = "optional";
View
@@ -183,7 +183,7 @@ function forum_print_post(&$post, $courseid, $ownpost=false, $reply=false, $link
$numwords = count_words($post->message);
echo "<A HREF=\"$CFG->wwwroot/mod/forum/discuss.php?d=$post->discussion\">";
echo get_string("readtherest", "forum");
- echo "</A> (".get_string("numwords", "forum", $numwords).")...";
+ echo "</A> (".get_string("numwords", "", $numwords).")...";
} else {
// Print whole message
echo text_to_html($post->message);
@@ -3,8 +3,8 @@
<TEXTAREA NAME=text COLS=60 ROWS=10 WRAP="virtual"><? p($entry->text) ?></TEXTAREA>
<P>
<INPUT type="hidden" name=id value="<?=$cm->id ?>">
-<INPUT type="submit" value="Save and continue">
-<INPUT type="reset" value="Revert">
+<INPUT type="submit" value="<? print_string("savechanges") ?>">
+<INPUT type="reset" value="<? print_string("revert") ?>">
</P>
</FORM>
</BLOCKQUOTE>
@@ -57,14 +57,18 @@
/// Otherwise fill and print the form.
+ $strjournal = get_string("modulename", "journal");
+ $strjournals = get_string("modulenameplural", "journal");
+ $stredit = get_string("edit");
+
if (! $entry ) {
$entry->text = "";
}
print_header("$course->shortname: $journal->name", "$course->fullname",
"<A HREF=/course/view.php?id=$course->id>$course->shortname</A> ->
- <A HREF=/mod/journal/index.php?id=$course->id>Journals</A> ->
- <A HREF=\"view.php?id=$cm->id\">$journal->name</A> -> Edit", "form.text");
+ <A HREF=/mod/journal/index.php?id=$course->id>$strjournals</A> ->
+ <A HREF=\"view.php?id=$cm->id\">$journal->name</A> -> $stredit", "form.text");
echo "<CENTER>\n";
View
@@ -16,7 +16,16 @@
$navigation = "<A HREF=\"../../course/view.php?id=$course->id\">$course->shortname</A> ->";
}
- print_header("$course->shortname: Journals", "$course->fullname", "$navigation Journals", "");
+ $strjournal = get_string("modulename", "journal");
+ $strjournals = get_string("modulenameplural", "journal");
+ $stredit = get_string("edit");
+ $strview = get_string("view");
+ $strweek = get_string("week");
+ $strtopic = get_string("topic");
+ $strquestion = get_string("question");
+ $stranswer = get_string("answer");
+
+ print_header("$course->shortname: $strjournals", "$course->fullname", "$navigation $strjournals", "");
if (! $journals = get_all_instances_in_course("journal", $course->id, "cw.section ASC")) {
@@ -27,13 +36,13 @@
$timenow = time();
if ($course->format == "weeks") {
- $table->head = array ("Week", "Question", "Answer");
+ $table->head = array ($strweek, $strquestion, $stranswer);
$table->align = array ("CENTER", "LEFT", "LEFT");
} else if ($course->format == "topics") {
- $table->head = array ("Topic", "Question", "Answer");
+ $table->head = array ($strtopic, $strquestion, $stranswer);
$table->align = array ("CENTER", "LEFT", "LEFT");
} else {
- $table->head = array ("Name", "Answer");
+ $table->head = array ($strquestion, $stranswer);
$table->align = array ("LEFT", "LEFT");
}
@@ -68,10 +77,10 @@
}
echo "<BR>";
+
print_table($table);
print_footer($course);
-
?>
View
@@ -1,22 +1,18 @@
<?PHP // $Id$
-$RATING = array ("3" => "Outstanding",
- "2" => "Satisfactory",
- "1" => "Not satisfactory");
+$JOURNAL_RATING = array ("3" => get_string("journalrating3", "journal"),
+ "2" => get_string("journalrating2", "journal"),
+ "1" => get_string("journalrating1", "journal") );
-function journal_user_summary($course, $user, $mod, $journal) {
- global $CFG;
-}
-
function journal_user_outline($course, $user, $mod, $journal) {
if ($entry = get_record_sql("SELECT * FROM journal_entries
WHERE user='$user->id' AND journal='$journal->id'")) {
$numwords = count(preg_split("/\w\b/", $entry->text)) - 1;
- $result->info = "$numwords words";
+ $result->info = get_string("numwords", "", $numwords);
$result->time = $entry->modified;
return $result;
}
@@ -31,7 +27,7 @@ function journal_user_complete($course, $user, $mod, $journal) {
print_simple_box_start();
if ($entry->modified) {
- echo "<P><FONT SIZE=1>Last edited: ".userdate($entry->modified)."</FONT></P>";
+ echo "<P><FONT SIZE=1>".get_string("lastedited").": ".userdate($entry->modified)."</FONT></P>";
}
if ($entry->text) {
echo text_to_html($entry->text);
@@ -144,15 +140,15 @@ function journal_print_user_entry($course, $user, $entry, $teachers, $ratings) {
echo "</TD>";
echo "<TD NOWRAP WIDTH=100% BGCOLOR=\"$THEME->cellheading\">$user->firstname $user->lastname";
if ($entry) {
- echo "&nbsp;&nbsp;<FONT SIZE=1>Last edited: ".userdate($entry->modified)."</FONT>";
+ echo "&nbsp;&nbsp;<FONT SIZE=1>".get_string("lastedited").": ".userdate($entry->modified)."</FONT>";
}
echo "</TR>";
echo "\n<TR><TD WIDTH=100% BGCOLOR=\"$THEME->cellcontent\">";
if ($entry) {
echo text_to_html($entry->text);
} else {
- echo "No entry";
+ print_string("noentry", "journal");
}
echo "</TD></TR>";
@@ -163,8 +159,8 @@ function journal_print_user_entry($course, $user, $entry, $teachers, $ratings) {
$entry->teacher = $USER->id;
}
print_user_picture($entry->teacher, $course->id, $teachers[$entry->teacher]->picture);
- echo "<TD BGCOLOR=\"$THEME->cellheading\">Teacher Feedback:";
- choose_from_menu($ratings, "r$entry->id", $entry->rating, "Rate...");
+ echo "<TD BGCOLOR=\"$THEME->cellheading\">".get_string("feedback").":";
+ choose_from_menu($ratings, "r$entry->id", $entry->rating, get_string("rate", "journal")."...");
if ($entry->timemarked) {
echo "&nbsp;&nbsp;<FONT SIZE=1>".userdate($entry->timemarked)."</FONT>";
}
@@ -226,7 +222,7 @@ function journal_delete_instance($id) {
function journal_print_feedback($course, $entry) {
- global $CFG, $THEME, $RATING;
+ global $CFG, $THEME, $JOURNAL_RATING;
if (! $teacher = get_record("user", "id", $entry->teacher)) {
error("Weird journal error");
@@ -246,11 +242,11 @@ function journal_print_feedback($course, $entry) {
echo "\n<TR><TD WIDTH=100% BGCOLOR=\"$THEME->cellcontent\">";
echo "<P ALIGN=RIGHT><FONT SIZE=-1><I>";
- if ($RATING[$entry->rating]) {
- echo "Overall rating: ";
- echo $RATING[$entry->rating];
+ if ($JOURNAL_RATING[$entry->rating]) {
+ echo get_string("overallrating", "journal").": ";
+ echo $JOURNAL_RATING[$entry->rating];
} else {
- echo "No rating given";
+ print_string("noratinggiven");
}
echo "</I></FONT></P>";
View
@@ -1,31 +1,31 @@
<form name="form" method="post" action="<?=$ME ?>">
<table cellpadding=5>
<tr valign=top>
- <td align=right><P><B>Journal Name:</B></P></TD>
+ <td align=right><P><B><? print_string("journalname", "journal") ?>:</B></P></TD>
<td>
<input type="text" name="name" size=30 value="<? p($form->name) ?>">
</td>
</tr>
<tr valign=top>
- <td align=right><P><B>Journal Question:</B></P></TD>
+ <td align=right><P><B><? print_string("journalquestion", "journal") ?>:</B></P></TD>
<td>
<textarea name="intro" rows=15 cols=30 wrap="virtual"><? p($form->intro) ?></textarea>
</td>
</tr>
<tr valign=top>
- <TD align=right><P><B>Days available:</B></P></TD>
+ <TD align=right><P><B><? print_string("daysavailable", "journal") ?>:</B></P></TD>
<TD>
<?
$options = array();
- $options[0] = "Always open";
+ $options[0] = get_string("alwaysopen", "journal");
for ($i=1;$i<=13;$i++) {
- $options[$i] = "$i days";
+ $options[$i] = get_string("numdays", "", $i);
}
for ($i=2;$i<=16;$i++) {
$days = $i * 7;
- $options[$days] = "$i weeks";
+ $options[$days] = get_string("numweeks", "", $i);
}
- $options[365] = "1 year";
+ $options[365] = get_string("numweeks", "", 52);
if ($form->days == "") {
$form->days == "14";
}
@@ -94,14 +94,14 @@
if ($usersdone = journal_get_users_done($journal)) {
foreach ($usersdone as $user) {
$entry = $entrybyuser[$user->id];
- journal_print_user_entry($course, $user, $entry, $teachers, $RATING);
+ journal_print_user_entry($course, $user, $entry, $teachers, $JOURNAL_RATING);
}
}
foreach ($users as $user) {
if (! $usersdone[$user->id]) {
$entry = NULL;
- journal_print_user_entry($course, $user, $entry, $teachers, $RATING);
+ journal_print_user_entry($course, $user, $entry, $teachers, $JOURNAL_RATING);
}
}
echo "<CENTER>";
View
@@ -28,12 +28,16 @@
if ($course->category) {
$navigation = "<A HREF=\"../../course/view.php?id=$course->id\">$course->shortname</A> ->";
}
+
+ $strjournal = get_string("modulename", "journal");
+ $strjournals = get_string("modulenameplural", "journal");
+
print_header("$course->shortname: $journal->name", "$course->fullname",
- "$navigation <A HREF=index.php?id=$course->id>Journals</A> -> $journal->name", "", "", true,
+ "$navigation <A HREF=index.php?id=$course->id>$strjournals</A> -> $journal->name", "", "", true,
update_module_icon($cm->id, $course->id));
if (isteacher($course->id)) {
- echo "<P align=right><A HREF=\"report.php?id=$cm->id\">View all responses</A></P>";
+ echo "<P align=right><A HREF=\"report.php?id=$cm->id\">".get_string("viewallentries","journal")."</A></P>";
}
echo "<CENTER>\n";
@@ -65,49 +69,49 @@
if ($timenow < $timefinish) {
$options = array ("id" => "$cm->id");
echo "<CENTER>";
- print_single_button("edit.php", $options, "Start or edit my journal entry");
+ print_single_button("edit.php", $options, get_string("startoredit","journal"));
echo "</CENTER>";
}
if ($entry = get_record_sql("SELECT * FROM journal_entries
WHERE user='$USER->id' AND journal='$journal->id'")) {
if (empty($entry->text)) {
- echo "<P ALIGN=center><B>Blank entry</B></P>";
+ echo "<P ALIGN=center><B>".get_string("blankentry","journal")."</B></P>";
} else {
echo text_to_html($entry->text);
}
} else {
- echo "<B><I>You have not started this journal yet.</I></B>";
+ echo "<B><I>".get_string("notstarted","journal")."</I></B>";
}
print_simple_box_end();
if ($timenow < $timefinish) {
if ($entry->modified) {
- echo "<P><FONT SIZE=-2><B>Last edited:</B> ";
+ echo "<P><FONT SIZE=-2><B>".get_string("lastedited").":</B> ";
echo userdate($entry->modified);
- echo " (".count_words($entry->text)." words)";
+ echo " (".get_string("numwords", "", count_words($entry->text)).")";
echo "</FONT></P>";
}
if ($journal->days) {
- echo "<P><FONT SIZE=-2><B>Editing period ends:</B> ";
+ echo "<P><FONT SIZE=-2><B>".get_string("editingends", "journal").":</B> ";
echo userdate($timefinish)."</FONT></P>";
}
} else {
- echo "<P><FONT SIZE=-2><B>Editing period has ended:</B> ";
+ echo "<P><FONT SIZE=-2><B>".get_string("editingended", "journal").":</B> ";
echo userdate($timefinish)."</P>";
}
if ($entry->comment || $entry->rating) {
- print_heading("Feedback");
+ print_heading(get_string("feedback"));
journal_print_feedback($course, $entry);
}
} else {
- echo "<P><B>This journal won't be open until: ";
+ echo "<P><B>".get_string("notopenuntil", "journal").": ";
echo userdate($timestart)."</B></P>";
}

0 comments on commit 3db1919

Please sign in to comment.