Studio Zero
« Add Content to End of Miniprofile »

Welcome Guest. Please Login or Register.
Sept 3, 2010, 4:33am





Studio Zero :: Web Development :: Code Storage :: Add Content to End of Miniprofile
   [Search This Thread][Send Topic To Friend] [Print]
 AuthorTopic: Add Content to End of Miniprofile (Read 1,893 times)
Bruce Banner
Head Coder
******
Click Click Boom
member is offline

[avatar]



Joined: Nov 2006
Gender: Male
Posts: 17,332
Location: Nebraska
Karma: 311
 Add Content to End of Miniprofile
« Thread Started on Dec 7, 2007, 4:13am »

Code:
<script type="text/Javascript">
// Add Content to End of Miniprofile by Chris
// Do not redistribute without permission of the creator

var aTD = document.getElementsByTagName("td");
function addContent(un, da){
    if(location.href.match(/action=(display|(calendar|pm)?view)/i) || document.title.match(/\s-\s(Preview|Search\sResults)/i)){
        for(a=0;a<aTD.length;a++){
            if(aTD[a].width == "20%" && aTD[a].innerHTML.match(new RegExp("user="+un+"[\"'\\s>]", "i"))){
                aTD[a].innerHTML += da;
            }
        }
    }
}

// SYNTAX: addContent("username_of_the_user", "HTML here to be added. Make sure to use <br /> to add line breaks.");
// Repeat line as necessary.
addContent("username", "Data here.");
</script>


Global footers. Main footers if you want it only in the main profile.

This code allows you to add HTML to the end of a user's miniprofile. This can be useful for adding awards for a user.
« Last Edit: Jul 20, 2009, 2:18am by Bruce Banner »Link to Post - Back to Top  IP: Logged

[image]
[image]

Coming soon(er or later) to SZ:
- [user] and [pmuser] UBBC tags
- Houdini
- CIv4
- Project Apocalypse
- Minimizer
   [Search This Thread][Send Topic To Friend] [Print]


Click Here To Make This Board Ad-Free


This Board Hosted For FREE By ProBoards
Get Your Own Free Message Boards & Free Forums!
Terms of Service | Privacy Policy | Report Abuse | Mobile