From 2ede0b1c811657827c388c4a0559063f4f02f025 Mon Sep 17 00:00:00 2001 From: Vjacheslav Trushkin Date: Thu, 9 Feb 2012 17:10:16 +0200 Subject: [PATCH] [feature/ajax] Better handling for zebra Better handling for zebra: message is displayed instead of first .zebra. Other .zebra entries are emptied, but not completely removed to avoid changing layout. PHPBB3-10272 --- phpBB/styles/prosilver/template/ajax.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/phpBB/styles/prosilver/template/ajax.js b/phpBB/styles/prosilver/template/ajax.js index 739648200b..35e8d6c0b4 100644 --- a/phpBB/styles/prosilver/template/ajax.js +++ b/phpBB/styles/prosilver/template/ajax.js @@ -41,8 +41,8 @@ phpbb.add_ajax_callback('zebra', function(res) { if (res.success) { zebra = $('.zebra'); - zebra.html(res.MESSAGE_TEXT); - $(zebra.get(1)).remove(); + zebra.first().html(res.MESSAGE_TEXT); + zebra.not(':first').html(' ').prev().html(' '); } });