Good art is a taste, good design is an opinion.


Come as guest, stay as family.
Board Index

Come as guest, stay as family.


You are not connected. Please login or register

Foto

[Solved] Thank Topic Starter



View previous topic View next topic Go down Message [Page 1 of 1]

1
Offline

  FrOsTyXi

avatar
V.I.P. Member
V.I.P. Member
  • Description:
Hello! I have this JavaScript to thank the topic starter and for some reason it's not functionalanymore may i have some help to sort this issue?

Here is the code:
$(function () {
var x = $('.post').get();
for (i = 0; i < x.length; i++) {
if (x[i].getAttribute('style') == "background-color:#ddebca;") {
x[i].style.backgroundColor = '';
x[i].firstChild.nextSibling.style.backgroundColor = '';
x[i].firstChild.nextSibling.firstChild.style.backgroundColor = '';
x[i].firstChild.nextSibling.firstChild.nextSibling.style.backgroundColor = '';
var stars = document.createElement('div');
stars.setAttribute('style', 'text-align: center;');
stars.innerHTML = '<hr><div style="padding-top:2px;height:32px;line-height:36px;color:#0000FF;font-size:16px;font-weight:bold;text-align:center"><img style="vertical-align:top" src="http://i59.servimg.com/u/f59/18/83/30/50/imagee14.png"> The Topic Starter Thanks You! <img style="vertical-align:top" src="http://i59.servimg.com/u/f59/18/83/30/50/imagee14.png"></div>';
x[i].firstChild.nextSibling.firstChild.nextSibling.appendChild(stars);
}
}
});
Thank you for any help.

Regards
FrOsTyXi

  • Information:
Forum:http://www.team-psn.net/Version:PUNBB
Type:Errors in codeTags:Thank,Topic,Starter

Powered by PunBB
Currently 0 users have thanked FrOsTyXi for this post:

2
Offline

  Shadow

avatar
Administrator
Administrator
Have you tried this one?

Code:
[panda=js]var CopyrightNotice = 'New thank-you system for forumotion PunBB boards. Copyright © 2012 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() {
    $('.post[style="background-color:#;"] .post-options').prepend('<div style="height:32px;line-height:36px;color:#740;font-size:16px;font-weight:bold;text-align:center"><img style="vertical-align:top" src="http://i59.servimg.com/u/f59/18/83/30/50/imagee14.png" />  The topic starter thanks you, '+$('.post[style="background-color:#;"] .user-ident').text()+'!  <img style="vertical-align:top" src="http://i59.servimg.com/u/f59/18/83/30/50/imagee14.png" /></div>');
});

Powered by PunBB
Currently 0 users have thanked Shadow for this post:

3
Offline

  FrOsTyXi

avatar
V.I.P. Member
V.I.P. Member
thank you solved!

Powered by PunBB
Currently 0 users have thanked FrOsTyXi for this post:

4
Offline

  Van-Helsing

avatar
★Moderator★
★Moderator★
[sucesso="Marked as Solved"]The question(s) in this topic have been answered and the owner has been able to solve the problem. Because of this, the topic has been marked as Solved.

If you have further questions, please open a new topic.[/sucesso]

Powered by PunBB
Currently 0 users have thanked Van-Helsing for this post:

5
Offline

  Sponsored content



Powered by PunBB
Currently 0 users have thanked Sponsored content for this post:

View previous topic View next topic Back to top Message [Page 1 of 1]


Topic URL's

URL
BBcode
HTML

Permissions in this forum:
You cannot reply to topics in this forum