vForums Support Banner



 

Welcome Guest! Please Login or Register
vForums Support :: Programming & Coding :: Code Requests & Support :: [Request] Happy Birthday in news fader - View Topic
Topic Rating: *****
Printable View
Nick
Very Senior Member
*****

[Avatar]

Posts: 3,013
Status: Offline
Gender: Male
Location: vForums
Age: 35
Joined:  
Reputation: 62%  


pmwww
[Request] Happy Birthday in news fader (27th Jan 08 at 2:10am UTC)
Im requesting, a Happy Birthday thing in the news fader, just like the code, that says. Welcome to new member [user]

Darkmage
Ross
Administrator
*****

[Avatar]

Posts: 3,709
Status: Offline
Gender: Male
Age: 9 14
Joined:  

Additional Groups:
Support Team
***


Reputation: 45%  


pmwwwtwittergtalkvForum
Re: [Request] Happy Birthday in news fader (31st Jan 08 at 10:01am UTC)
Code: JavaScript
 
  1. <script type="text/javascript">
  2. <!--
  3. /* Show Todays Birthdays in the News Fader - Open Source */
  4. if(bdays = get('birthdays', ID)) {
  5. var birthdays = bdays.getElementsByTagName('div').item(0).innerHTML;
  6. } else {
  7. var birthdays = "<i>Nobody</i>";
  8. }
  9. if("undefined" != typeof news) {
  10. for(n=0; n<news.length; n++) {
  11. news[n] = news[n].replace(/\[birthdays\]/, birthdays);
  12. }
  13. }
  14. else if(get('forum_news', ID)) {
  15. news_table = get('forum_news', ID);
  16. news_table.innerHTML = news_table.innerHTML.replace(/\[birthdays\]/, birthdays);
  17. }
  18. //-->
  19. </script>
 


Place that in the main footer. Then place [birthdays] in the news fader to display the birthdays {Smile}

Image
 Printable View

All times are GMT+0 :: The current time is 2:13pm
Page generated in 0.288 seconds
This Forum is Powered By vForums (v2.4)
Create a Forum for Free | Find Forums