Respuestas en este Tema
Adi#2
Mata.com
Vin Mar 06, 2015 12:30 pm
Pentru inceput intra in : ' Panou de administrare => Afisare => Culori => Foaie de stil css ' si adauga codul de mai jos.
Apoi intra in: ' Panou de administrare => Afisare => Template-uri => General => index_box ' si cautati codul de mai jos.
Succes
- Cod:
/* Specialized Favorites by Devs / */
#indexBox .zzheart{display:inline-block;background:url(//i56.servimg.com/u/f56/18/59/49/93/heart10.png) no-repeat;background-position:0 0;width:16px;height:16px;cursor:pointer;margin-left:5px;opacity:.5;-webkit-transition:opacity .5s ease;-moz-transition:opacity .5s ease;-o-transition:opacity .5s ease;transition:opacity .5s ease}
#indexBox .zzlove{background-position:0 -16px}
#indexBox .zzheart:hover{opacity:1}
Apoi intra in: ' Panou de administrare => Afisare => Template-uri => General => index_box ' si cautati codul de mai jos.
- Cod:
<div class="main">
- Cod:
<div id="indexBox" class="main">
- Cod:
<!-- BEGIN switch_on_index -->
- Cod:
<!-- Specialized Favorites by Devs -->
<script type="text/javascript">
//<![CDATA[
var zzfavourite = {
wrapAll: "#indexBox",
title: "#indexBox .forumtitle",
item: "tr",
wrapItem: ".statused",
boxContent: ".main-content",
favouriteCal: '<div class="main-head favouriteBox"><div class="page-title"><h2>Favourites</h2></div></div><div class="main-content favouriteBox"><table cellspacing="0" class="table"><thead><tr><th class="tcl">Forum</th><th class="tc2">Topics</th><th class="tc3">Posts</th><th class="tcr">Last Posts</th></tr></thead><tbody id="favourites" class="statused"></tbody></table></div>',
pageIndex: "",
favouriteBox: function () {
$("#favourites").length || $(zzfavourite.wrapAll).prepend(zzfavourite.favouriteCal)
},
start: function () {
if ("/" == location.pathname || "/forum" == location.pathname) zzfavourite.pageIndex = !0;
$(zzfavourite.title).after('<div class="zzheart"></div>');
$(zzfavourite.wrapAll).on("click", ".zzheart", function () {
var t = $(this);
if (t.hasClass("zzlove")) {
var c = t.prev().attr("href"),
a = RegExp("\\b" + c.match(/\/f(\d+)-.*/)[1] + "\\b\\s?");
my_setcookie("favouriteBox", my_getcookie("favouriteBox").replace(a, ""), !0);
t.removeClass("zzlove");
if (zzfavourite.pageIndex) {
var d = t.closest(zzfavourite.item),
b = $(zzfavourite.title + "[href='" + c + "']:last").closest(zzfavourite.item);
d.fadeOut(300, function () {
b.closest(zzfavourite.boxContent).is(":hidden") && b.closest(zzfavourite.boxContent).fadeIn().prev().fadeIn();
b.find(".zzheart").removeClass("zzlove").end().fadeIn(300);
d.remove();
$("#favourites " + zzfavourite.item).length || $(".favouriteBox").remove()
})
}
} else if (c = t.prev().attr("href").match(/\/f(\d+)-.*/)[1], t.addClass("zzlove"),
a = my_getcookie("favouriteBox"), null == a || "" == a ? my_setcookie("favouriteBox", c, !0) : RegExp("\\b" + c + "\\b\\s?").test(a) || my_setcookie("favouriteBox", a + " " + c, !0), zzfavourite.pageIndex) {
zzfavourite.favouriteBox();
var e = t.closest(zzfavourite.item);
e.fadeOut(300, function () {
e.clone().appendTo("#favourites").fadeIn(300);
0 == t.closest(zzfavourite.wrapItem).height() && t.closest(zzfavourite.boxContent).hide().prev().hide()
})
}
});
var b = my_getcookie("favouriteBox");
null != b && "" != b && ($.each($.trim(b).split(" "), function (c, a) {
var d = $(zzfavourite.title + "[href^='/f" + a + "-']");
d.next().addClass("zzlove");
zzfavourite.pageIndex && (zzfavourite.favouriteBox(), d.closest(zzfavourite.item).hide().clone().appendTo("#favourites").show(), 0 == d.closest(zzfavourite.wrapItem).height() && d.closest(zzfavourite.boxContent).hide().prev().hide())
}), $("#favourites").is(":empty") && $(".favouriteBox").remove())
}
};
zzfavourite.start();
//]]>
</script>
Succes