[css][جافا][PHPBB3] صندوق اخر 10 مواضيع في المنتدى بدون تمبلتالكود خاص بالنسخة
صورة الكود
شرح التنصيب:
الان الى الاكواد
نضع كود الجافا هذا في صفحة الجافا
- الكود:
-
var CopyrightNotice = 'Reformatted Recent Topics widget script for
forumotion phpBB3 and Invision boards. Copyright © 2011 by Dion Designs.
All Rights Reserved. Use and/or modification of this script is allowed,
provided this entire copyright notice remains in the original or
modified script. Distribution is not allowed without written consent
from Dion Designs.';
function rtnew() {
var y=document.createElement('div');
y.id='rtopic';
var x=$('#right .module')[0];
var au=$(x).find('a:odd').get();
var to=$(x).find('a:even').get();
for (i=au.length-1;i>=0;i--) {
var z=document.createElement('tr');
var time=au[i].nextSibling.nodeValue;
z.appendChild(au[i]);
z.insertBefore(to[i],au[i]);
$(au[i]).before('<td>'+time+'</td>');
$(au[i]).wrap('<td></td>');
$(to[i]).wrap('<td></td>');
y.insertBefore(z,y.firstChild);
}
y.innerHTML='<div id="rtitle"><b>اخر
المواضيع</b></div><table id="rtable"
cellspacing="0"><tr><th
class="ddto"><b>المواضيع</b></th><th
class="ddti"><b>وقت الاضافة</b></th><th
class="ddau"><b>الكاتب</b></th></tr>'+y.innerHTML+'</table>';
$('#content-container').before(y);
}
$(function() {
if (document.getElementById('chatbox_popup')) {rtnew();}
$('#right .module').eq(0).remove();
});
ونعينه في جميع الصفحات
ولتنسيقه نضيف كود css
- الكود:
-
#rtopic {width:900px;margin:10px auto;padding:0 6px
5px;background:#1675bc;font-family:Verdana;font-size:12px;text-align:center;border-radius:6px;}
#rtitle {height:30px;line-height:30px;color:#fff;font-size:14px;}
#rtable {width:100%;border-collapse:collapse;}
#rtable th {padding:5px 0;background:#cadceb;border:1px solid #1675bc;}
#rtable td {padding:5px;background:#fff;border:1px solid #1675bc;font-family:Tahoma;}
.ddto {width:50%;}
.ddti {width:25%;}
.ddau {width:auto;}