We hope you enjoy your visit.

You're currently viewing our forum as a guest. This means you are limited to certain areas of the board and there are some features you can't use. If you join our community, you'll be able to access member-only sections, and use many member-only features such as customizing your profile, sending personal messages, and voting in polls. Registration is simple, fast, and completely free.


Join our community!


If you're already a member please log in to your account to access all of our features:

Username:   Password:
Locked Topic
[ C ] Award code in signatures
Topic Started: Jul 23 2011, 02:26 AM (639 Views)
familywin
Member
[ *  * ]
Board Address: Private
Board Software: ZetaBoards
Description: Please help me create a code rewards the member's signature. maybe it has more frames, etc. ..thank you so much
Offline Profile Goto Top
 
Cory
Member Avatar
Member
[ *  *  *  *  *  *  *  *  * ]
So basically you're wanting to add awards to the users signature?
Offline Profile Goto Top
 
familywin
Member
[ *  * ]
Yes, Cory
Offline Profile Goto Top
 
Cory
Member Avatar
Member
[ *  *  *  *  *  *  *  *  * ]
Admin CP Posted Image Themes Posted Image Board Template Posted Image Below the Board
Code:
 
<script type="text/javascript">
function addAward(username, image) {
$("td.c_username:contains(" + username + ")").parent().next().next().find("td.c_nosig, td.c_sig").prepend("<img src='" + image + "' alt='Award' />");
}

addAward("USERNAME", "IMAGE_URL");
</script>
Replace 'USERNAME' and 'IMAGE_URL' and keep repeating that line for more users.
Offline Profile Goto Top
 
familywin
Member
[ *  * ]
Thank Cory, but it is not desired by me. You can help me once again, look at it like this. Sorry for your loss of time, I should bring you images earlier example

Spoiler: click to toggle
Offline Profile Goto Top
 
Cory
Member Avatar
Member
[ *  *  *  *  *  *  *  *  * ]
Code:
 
<script type="text/javascript">
$("td.c_nosig, td.c_sig").append("<fieldset><legend>My Awards</legend></fieldset>");

function addAward(username, image) {
$("td.c_username:contains(" + username + ")").parent().next().next().find("td.c_nosig fieldset, td.c_sig fieldset").append("<img src='" + image + "' alt='Award' />");
}

addAward("USERNAME", "IMAGE_URL");

$("td.c_sig fieldset, td.c_nosig fieldset").css("display", "none");
$("td.c_sig fieldset:has(img), td.c_nosig fieldset:has(img)").css("display", "block");
</script>
Try that instead.
Offline Profile Goto Top
 
familywin
Member
[ *  * ]
how a member of many award, Cory.
Offline Profile Goto Top
 
Cory
Member Avatar
Member
[ *  *  *  *  *  *  *  *  * ]
Code:
 
addAward("USERNAME", "IMAGE_URL");
You have to edit that line and keep repeating it to give a user more awards or a different user some awards.
Offline Profile Goto Top
 
familywin
Member
[ *  * ]
oh, i know. I mean Mem 1 have award 1, award 2,...more
Offline Profile Goto Top
 
Cory
Member Avatar
Member
[ *  *  *  *  *  *  *  *  * ]
If you mean giving multiple awards to one user, you can do it like this:
Code:
 
addAward("familywin", "IMAGE_URL");
addAward("familywin", "IMAGE_URL");
Offline Profile Goto Top
 
familywin
Member
[ *  * ]
Thank you very much, it working perfect.
Offline Profile Goto Top
 
Roby-ZNR
Member Avatar
Efficacy
[ *  *  *  *  *  * ]
Completed!

Your request has been completed. If you have any questions or concerns regarding the state of your request, please feel free to contact me via PM.
Offline Profile Goto Top
 
1 user reading this topic (1 Guest and 0 Anonymous)
« Previous Topic · Closed Requests · Next Topic »
Locked Topic