[How To] Add a Hidden Birthday Table in the Header

How-to's, little tricks, tutorials, code examples (snippets) and read-me's.

[How To] Add a Hidden Birthday Table in the Header

Postby Sniper_E » 04 Mar 2007, 23:11

This is how you can add a hidden birthday table in the header.
Spoiler:
Code: Select all
// OPEN styles/subSilver/overall_header.html

// FIND

<!-- IF not S_USER_LOGGED_IN -->
    <
br clear="all" />

    <
form method="post" action="<!-- IF S_LOGIN_ACTION -->{S_LOGIN_ACTION}<!-- ELSE -->{U_LOGIN_LOGOUT}<!-- ENDIF -->">
    <
table class="tablebg" width="100%" cellspacing="1">
    <
tr>
        <
td class="cat" colspan="2"><h4><a href="{U_LOGIN_LOGOUT}">{L_LOGIN_LOGOUT}</a></h4></td>
    </
tr>
    <
tr class="row1">
        <
td align="center"><span class="genmed">{L_USERNAME}:</span> <input class="post" type="text" name="username" size="10" />&nbsp; <span class="genmed">{L_PASSWORD}:</span> <input class="post" type="password" name="password" size="10" />&nbsp; <span class="gensmall">{L_LOG_ME_IN}</span> <input type="checkbox" checked="checked" class="radio" name="autologin" />&nbsp; <input type="submit" class="btnmain" name="login" value="{L_LOGIN}" /></td><td> &nbsp;<a href="{U_REGISTER}"><img src="{T_THEME_PATH}/images/icon_mini_register.gif" width="12" height="13" border="0" alt="{L_REGISTER}" /> {L_REGISTER}</a></td>
    </
tr>
    </
table>
    
    </
form>
<!-- ENDIF -->

// AFTER </forum> ADD

<!-- ELSEIF S_DISPLAY_BIRTHDAY_LIST and BIRTHDAY_LIST -->
<
br />
<
table class="tablebg" width="100%" cellspacing="1">
    <
tr>
        <
th><h4>{L_BIRTHDAYS}</h4></th>
    </
tr>
    <
tr>
        <
td class="row1 genmed">{L_CONGRATULATIONS}: <b>{BIRTHDAY_LIST}</b></td>
    </
tr>
</
table>
<
br />

// CLOSE and SAVE
Anytime a registered member's birthday comes up, that table will appear at the top of your page.

Edited: And/Or, if you wanted to have your birthday list hidden in the bottom of your index_body.html page.
Spoiler:
Code: Select all
// OPEN styles/subSilver/index_body.html

// FIND

<!-- IF S_DISPLAY_BIRTHDAY_LIST -->

// REPLACE WITH

<!-- IF S_DISPLAY_BIRTHDAY_LIST and BIRTHDAY_LIST -->

// CLOSE and SAVE
I just noticed angelside had this tip listed already.
Image
No is NEVER an Option and NEVER is the only Option when it comes to Giving Up!
User avatar
Sniper_E    
STG Jedi Master
STG Jedi Master
 
Posts: 6981
Joined: 31 May 2006, 06:29
Location: Shreveport, LA
Favorite Team: The STG Team
Gender: Male
phpBB Knowledge: 6




phpBB Academy at StarTrekGuide
Support STG
Using PayPal Donate

Re: [How To] Add a Hidden Birthday Table in the Header

Postby Sniper_E » 05 Mar 2007, 13:28

I took OUT the DISPLAY_BIRTHDAY_LIST table in the bottom of the index_body page.
I moved it into the lower table just below the Statistics section.
If you look and don't see anything there, that's because there is no new birthday today.
Let's wait until a birthday rolls around and see what happens.

I did not do this in the overall_header page for it to appear in the top of the page because Highway has something written up there already and I will not alter or move anything that Highway or Hanyman does in these pages. Well, that's a lie because I added a couple of <br />s in what he had up there.... but don't tell him cause I might get in trouble.

The test is on!
Image
No is NEVER an Option and NEVER is the only Option when it comes to Giving Up!
User avatar
Sniper_E    
STG Jedi Master
STG Jedi Master
 
Posts: 6981
Joined: 31 May 2006, 06:29
Location: Shreveport, LA
Favorite Team: The STG Team
Gender: Male
phpBB Knowledge: 6

Re: [How To] Add a Hidden Birthday Table in the Header

Postby Highway of Life » 05 Mar 2007, 13:53

Go ahead and remove it... it won?t apply until next year, plus a certain MOD will replace that anyways.
Watch out! I might do a code wheelie!

User avatar
Highway of Life    
STG Jedi Master
STG Jedi Master
 
Posts: 10458
Joined: 08 May 2006, 05:23
Location: Beware of Programmers carrying screwdrivers
Gender: Male
phpBB Knowledge: 10

Re: [How To] Add a Hidden Birthday Table in the Header

Postby Sniper_E » 05 Mar 2007, 23:15

Yeah! The birthday table showed up!!!

Too bad it was for Kakashi306 who joined Nov. 11th last visit Nov. 12th and has no posts.
Not a formidable member to be celebrating. We should limit this to a max # of posts also.

I love it when a plan comes together.... Yahoo
Image
No is NEVER an Option and NEVER is the only Option when it comes to Giving Up!
User avatar
Sniper_E    
STG Jedi Master
STG Jedi Master
 
Posts: 6981
Joined: 31 May 2006, 06:29
Location: Shreveport, LA
Favorite Team: The STG Team
Gender: Male
phpBB Knowledge: 6

Re: [How To] Add a Hidden Birthday Table in the Header

Postby Sniper_E » 06 Mar 2007, 21:51

Aight.... It's countdown time for that Birthday Table.... 1 Hour and 9 Minutes and it should disappear!
Image
No is NEVER an Option and NEVER is the only Option when it comes to Giving Up!
User avatar
Sniper_E    
STG Jedi Master
STG Jedi Master
 
Posts: 6981
Joined: 31 May 2006, 06:29
Location: Shreveport, LA
Favorite Team: The STG Team
Gender: Male
phpBB Knowledge: 6

Re: [How To] Add a Hidden Birthday Table in the Header

Postby Handyman » 07 Mar 2007, 00:12

Yep? eez gone? vanished? is no more? deleted? banish? oh, sorry.
Please contact me if you have any news to submit to SCOFF News.
SCOFFing at the candidates while you sleep.
My Mods || My Mod Queue
Image
User avatar
Handyman    
Rear Fleet Admiral
Rear Fleet Admiral
 
Posts: 7454
Joined: 08 May 2006, 04:45
Location: Where no man has gone before!
Favorite Team: Seattle Seahawks
Gender: Male

Re: [How To] Add a Hidden Birthday Table in the Header

Postby Highway of Life » 18 Mar 2007, 07:09

Looks good Sniper! Good
I noticed it only shows up on the index page... this is fine.

I?m going to try and move the spacing from <br /> tags to the stylesheet... much better that way. Smile
Watch out! I might do a code wheelie!

User avatar
Highway of Life    
STG Jedi Master
STG Jedi Master
 
Posts: 10458
Joined: 08 May 2006, 05:23
Location: Beware of Programmers carrying screwdrivers
Gender: Male
phpBB Knowledge: 10

Re: [How To] Add a Hidden Birthday Table in the Header

Postby MikeR » 24 May 2007, 14:24

This doesn't work with RC1? I attempted to look up that text in styles/subsilver2/template/overall_header.html and couldn't find any of it.
Any ideas?
If it exists in the real world, it can be created in 3D
MikeR
Borg Drone
Borg Drone
 
Posts: 169
Joined: 01 Apr 2007, 08:32
Location: California
Favorite Team: none
Gender: Male

Re: [How To] Add a Hidden Birthday Table in the Header

Postby Sniper_E » 24 May 2007, 15:01

Do you think it could be added to the top of the index_body.html instead of in the header?

I have the birthday greeting hid in the statistics below in the index so I know it can be hidden at the top.

I'll look in a little bit. It can be added where ever you want it.
Image
No is NEVER an Option and NEVER is the only Option when it comes to Giving Up!
User avatar
Sniper_E    
STG Jedi Master
STG Jedi Master
 
Posts: 6981
Joined: 31 May 2006, 06:29
Location: Shreveport, LA
Favorite Team: The STG Team
Gender: Male
phpBB Knowledge: 6

Re: [How To] Add a Hidden Birthday Table in the Header

Postby MikeR » 24 May 2007, 16:42

I tried adding it to "viewforum_body.html" to see it inside the forum itself, but never could get it to show. (I copy/pasted the regular code so it was always visable) as I only have 1 forum on that particular board, so most of my users never see the front page. They link in to viewforum instead.

Spoiler:
<!-- IF S_DISPLAY_BIRTHDAY_LIST -->
<br clear="all" />

<table class="tablebg" width="100%" cellspacing="1">
<tr>
<td class="cat" colspan="2"><h4>{L_BIRTHDAYS}</h4></td>
</tr>
<tr>
<td class="row1" align="center" valign="middle"><img src="{T_THEME_PATH}/images/whosonline.gif" alt="{L_BIRTHDAYS}" /></td>
<td class="row1" width="100%"><p class="genmed"><!-- IF BIRTHDAY_LIST -->{L_CONGRATULATIONS}: <b>{BIRTHDAY_LIST}</b><!-- ELSE -->{L_NO_BIRTHDAYS}<!-- ENDIF --></p></td>
</tr>
</table>
<!-- ENDIF -->
If it exists in the real world, it can be created in 3D
MikeR
Borg Drone
Borg Drone
 
Posts: 169
Joined: 01 Apr 2007, 08:32
Location: California
Favorite Team: none
Gender: Male

Next

Return to Tutorials and How-Tos

Who is online

Users browsing this forum: Google [Bot] and 4 guests