From 01f0a5d16c4bf0092feb68a841bfa564757dd064 Mon Sep 17 00:00:00 2001 From: "Paul S. Owen" Date: Sat, 15 Sep 2001 23:51:41 +0000 Subject: Added theme row colour/class support git-svn-id: file:///svn/phpbb/trunk@1046 89ea8834-ac86-4346-8a33-228a782c2dd0 --- phpBB/admin/admin_smilies.php | 7 ++++++- phpBB/admin/admin_words.php | 5 +++++ phpBB/templates/PSO/admin/smile_list_body.tpl | 12 ++++++------ phpBB/templates/PSO/admin/words_list_body.tpl | 8 ++++---- 4 files changed, 21 insertions(+), 11 deletions(-) diff --git a/phpBB/admin/admin_smilies.php b/phpBB/admin/admin_smilies.php index 5a200b7401..d867d1ce81 100644 --- a/phpBB/admin/admin_smilies.php +++ b/phpBB/admin/admin_smilies.php @@ -310,9 +310,14 @@ switch($mode) // // Loop throuh the rows of smilies setting block vars for the template. // - for( $i = 0; $i < count($smilies); $i++ ) + for($i = 0; $i < count($smilies); $i++) { + $row_color = ( !($i % 2) ) ? $theme['td_color1'] : $theme['td_color2']; + $row_class = ( !($i % 2) ) ? $theme['td_class1'] : $theme['td_class2']; + $template->assign_block_vars("smiles", array( + "ROW_COLOR" => "#" . $row_color, + "ROW_CLASS" => $row_class, "SMILEY_IMG" => $phpbb_root_path . '/' . $board_config['smilies_path'] . '/' . $smilies[$i]['smile_url'], "CODE" => $smilies[$i]['code'], "EMOT" => $smilies[$i]['emoticon'], diff --git a/phpBB/admin/admin_words.php b/phpBB/admin/admin_words.php index 5d660a78c0..2b53198b49 100644 --- a/phpBB/admin/admin_words.php +++ b/phpBB/admin/admin_words.php @@ -209,7 +209,12 @@ else $replacement = $word_rows[$i]['replacement']; $word_id = $word_rows[$i]['word_id']; + $row_color = ( !($i % 2) ) ? $theme['td_color1'] : $theme['td_color2']; + $row_class = ( !($i % 2) ) ? $theme['td_class1'] : $theme['td_class2']; + $template->assign_block_vars("words", array( + "ROW_COLOR" => "#" . $row_color, + "ROW_CLASS" => $row_class, "WORD" => $word, "REPLACEMENT" => $replacement, "U_WORD_EDIT" => append_sid("admin_words.$phpEx?mode=edit&id=$word_id"), diff --git a/phpBB/templates/PSO/admin/smile_list_body.tpl b/phpBB/templates/PSO/admin/smile_list_body.tpl index f2a5ed4b95..645ce4a6a4 100644 --- a/phpBB/templates/PSO/admin/smile_list_body.tpl +++ b/phpBB/templates/PSO/admin/smile_list_body.tpl @@ -5,7 +5,7 @@

{L_SMILEY_TEXT}

-
+
@@ -14,11 +14,11 @@ - - - - - + + + + + diff --git a/phpBB/templates/PSO/admin/words_list_body.tpl b/phpBB/templates/PSO/admin/words_list_body.tpl index 1e39edb767..74db85cfc2 100755 --- a/phpBB/templates/PSO/admin/words_list_body.tpl +++ b/phpBB/templates/PSO/admin/words_list_body.tpl @@ -13,10 +13,10 @@ - - - - + + + + -- cgit v1.2.1
{L_CODE} {L_SMILE}
{smiles.CODE}{smiles.CODE}{smiles.EMOT}{L_EDIT}{L_DELETE}{smiles.CODE}{smiles.CODE}{smiles.EMOT}{L_EDIT}{L_DELETE}
{words.WORD}{words.REPLACEMENT}{L_EDIT}{L_DELETE}{words.WORD}{words.REPLACEMENT}{L_EDIT}{L_DELETE}