From efbbe2f0474abc662958470f986d38604952c764 Mon Sep 17 00:00:00 2001 From: Nadav Kavalerchik Date: Sat, 19 Nov 2011 23:10:43 +0200 Subject: [PATCH] MDL-29226 - right align table's cells, in Glossary edit categories page (when in RTL mode)(cherry picked from commit 9ace475) --- mod/glossary/editcategories.php | 19 ++++++++++++++----- 1 file changed, 14 insertions(+), 5 deletions(-) diff --git a/mod/glossary/editcategories.php b/mod/glossary/editcategories.php index 43e63400a48..3d8232d57a7 100644 --- a/mod/glossary/editcategories.php +++ b/mod/glossary/editcategories.php @@ -83,6 +83,15 @@ echo $OUTPUT->header(); $fmtoptions = array( 'context' => $context); +if (right_to_left()) { // RTL table alignment support + $rightalignemnt = 'left'; + $leftalignment = 'right'; +} else { + $rightalignemnt = 'right'; + $leftalignment = 'left'; + +} + if ( $hook >0 ) { if ( $action == "edit" ) { @@ -135,7 +144,7 @@ if ( $hook >0 ) { - - -
+
@@ -147,7 +156,7 @@ if ( $hook >0 ) {
+
+ ".format_string($category->name, true, $fmtoptions)." ($num_entries " . get_string("entries","glossary") . ")"; ?> @@ -245,9 +254,9 @@ if ( $action ) { $options['id'] = $cm->id; $options['action'] = "add"; - echo "
"; + echo "
"; echo $OUTPUT->single_button(new moodle_url("editcategories.php", $options), get_string("add") . " " . get_string("category","glossary")); - echo ""; + echo ""; unset($options['action']); $options['mode'] = 'cat'; $options['hook'] = $hook;