Text

Location Flags

 
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    howtodoit.myfreeforum.org Forum Index -> Add-on`s for your forum
View previous topic :: View next topic  
Author Message
symon
Site Admin
Site Admin

Location: 

Joined: 13 Mar 2006
Posts: 866


Location: Hampshire Add Karma

PostPosted: Tue Jun 05, 2007 3:06 pm    Post subject: Location Flags Reply with quote

Remember to backup your forum template and use editor before you do this incase something goes wrong.

Go to your forum's Administration Panel ----- 2. General --- Profile Fields

Now add FLAGS And click Add Custom Profile Field

You will now see this screen



Fill in the details to how you want them then click submit.

I would suggest these options in

Field type options

Type Drop down
Default Your country eg uk
Options this is where you enter the list of locations you want they must be the same as your image name(minus the .gif or .jpg etc) and are case sensitive. For example if you want to use the flags i list below make sure the name is exactly how it shows in the list so for the united kindom just add uk and for the states add usa, so you list may look like.

uk,usa,cuba,sweden

Display as image ---- This is where you enter the url to the images if you wish it to show as an image (leave blank for it to show text only).

The path to enter for the flags below is

Code:
/ranks/flags/{FLAGS}.gif


You have now set up your FLAG Field.

Which may look like this







The Guide below is ONLY for those that wish to edit or move the code to a place not given in the drop down bar in the screen above.

Please note That

Code:
{FLAGS}
is for text only for image replace all
Code:
{FLAGS}


With

Code:
<img src="/ranks/flags/{FLAGS}.gif">




Open profile_view_body.tpl and add where you want it to appear.(NOTE:IT is case sensitive, if the code below is capaltalized, keep it that way Wink )
Code:
<tr>
<td valign="middle" align="right" nowrap="nowrap"><span class="gen">{L_FLAGS}:&nbsp;</span></td>
<td><b><span class="gen">{FLAGS}</span></b></td>
</tr>


So I want it to appear after OCCUPATION So my code will look like this when im finished
Code:
 <td valign="middle" align="right" nowrap="nowrap"><span class="gen">{L_OCCUPATION}:&nbsp;</span></td>
        <td><b><span class="gen">{OCCUPATION}</span></b></td>
      </tr>
<tr>
<td valign="middle" align="right" nowrap="nowrap"><span class="gen">{L_FLAGS}:&nbsp;</span></td>
<td><b><span class="gen">{FLAGS}</span></b></td>
</tr>       
<tr>
        <td valign="top" align="right" nowrap="nowrap"><span class="gen">{L_INTERESTS}:</span></td>
        <td> <b><span class="gen">{INTERESTS}</span></b></td>
      </tr>
     </table>
   </td>
  </tr>


Alright open Profile_add_body.tpl
Add {FLAGS} where you want it to appear. So I want it to appear after OCCUPATION so my finished code looks like
Code:
<input type="text" class="post" style="width: 200px"  name="occupation" size="25" maxlength="100" value="{OCCUPATION}" />
     </td>
   </tr>{FLAGS}
   <tr>
     <td class="row1"><span class="gen">{L_INTERESTS}:</span></td>
     <td class="row2">
      <input type="text" class="post" style="width: 200px"  name="interests" size="35" maxlength="150" value="{INTERESTS}" />
     </td>
   </tr>


In viewtopic_body.Tpl
Add

Code:
<br />{postrow.FLAGS}


Please note for an Image you need
Code:
{postrow.FLAGS_IMG}


Where you would like it appear in this code area.

Code:
<!-- BEGIN postrow -->
   <tr>
      <td width="150" align="left" valign="top" class="{postrow.ROW_CLASS}"><span class="name"><a name="{postrow.U_POST_ID}"></a><b>{postrow.POSTER_NAME}</b></span><br /><span class="postdetails">{postrow.POSTER_RANK}<br />{postrow.RANK_IMAGE}{postrow.POSTER_AVATAR}<br />{postrow.POSTER_JOINED}<br />{postrow.POSTER_POSTS}<br />{postrow.POSTER_FROM}</span><br /></td>
      <td class="{postrow.ROW_CLASS}" width="100%" height="28" valign="top"><table width="100%" border="0" cellspacing="0" cellpadding="0">

So if I wanted it after the how many posts an user made, the code would look like this
Code:
Code:
<!-- BEGIN postrow -->
   <tr>
      <td width="150" align="left" valign="top" class="{postrow.ROW_CLASS}"><span class="name"><a name="{postrow.U_POST_ID}"></a><b>{postrow.POSTER_NAME}</b></span><br /><span class="postdetails">{postrow.POSTER_RANK}<br />{postrow.RANK_IMAGE}{postrow.POSTER_AVATAR}<br /><br />{postrow.POSTER_JOINED}<br />{postrow.POSTER_POSTS}<br /> {postrow.FLAGS}<br />{postrow.POSTER_FROM}</span><br /></td>
      <td class="{postrow.ROW_CLASS}" width="100%" height="28" valign="top"><table width="100%" border="0" cellspacing="0" cellpadding="0">





Last edited by symon on Tue Jul 24, 2007 7:24 pm; edited 5 times in total
Back to top
View user's profile Send private message
symon
Site Admin
Site Admin

Location: 

Joined: 13 Mar 2006
Posts: 866


Location: Hampshire Add Karma

PostPosted: Tue Jun 05, 2007 3:24 pm    Post subject: Reply with quote




afghanistan
albania
algeria
andorra
angola
antiguabarbuda
argentina
armenia
australia
austria
azerbaijan
bahamas
bahrain
bangladesh
barbados
belarus
belgium
belize
benin
bhutan
bolivia
bosnia_herzegovina
botswana
brazil
brunei
bulgaria
burkinafaso
burma
burund
cambodia
cameroon
canada
centralafricanrep
chad
chile
china
columbia
comoros
congo
costarica
croatia
cuba
cyprus
czechrepublic
demrepcongo
denmark
djiboutil
dominica
dominicanrep
ecuador
egypt
elsalvado
eq_guinea
eritrea
estonia
ethiopia
fiji
finland
france
gabon
gambia
georgia
germany
ghana
greece
grenada
grenadines
guatemala
guineabissau
guineal
guyana
haiti
honduras
hong_kong
hungary
iceland
india
indonesia
iran
iraq
ireland
israel
italy
ivorycoast
jamaica
japan
jordan
kazakhstan
kenya
kiribati
kuwait
kyrgyzstan
laos
latvia
lebanon
liberia
libya
liechtenstein
lithuania
luxembourg
macadonia
macau
madagascar
malawi
malaysia
maldives
mali
malta
mauritania
mauritius
mexico
micronesia
moldova
monaco
mongolia
morocco
mozambique
namibia
nauru
nepal
neth_antilles
netherlands
newzealand
nicaragua
niger
nigeria
north_korea
norway
oman
pakistan
panama
papuanewguinea
paraguay
peru
philippines
poland
portugal
puertorico
qatar
rawanda
romania
russia
sao_tome
saudiarabia
senegal
serbia
seychelles
sierraleone
singapore
slovakia
slovenia
solomon_islands
somalia
south_korea
southafrica
spain
srilanka
stkitts_nevis
stlucia
sudan
suriname
sweden
switzerland
syria
taiwan
tajikistan
tanzania
thailand
togo
tonga
trinidadandtobago
tunisia
turkey
turkmenistan
tuvala
uae
uganda
uk
ukraine
uruguay
usa
ussr
uzbekistan
vanuatu
venezuela
vietnam
western_samoa
yemen
yugoslavia
zaire
zambia
zimbabwe


Back to top
View user's profile Send private message
Display posts from previous:   
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    howtodoit.myfreeforum.org Forum Index -> Add-on`s for your forum All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

Card File  Gallery  Forum Archive
HOWTODOIT was designed and built by Symon Field
Creator Of ☆ FarnboroughInvinciblesAgonyAuntFairiesAsylum Alliance FunnyWorldHOWTODOIT PHPbb3
HOWTODOIT© Symon Field 2006,2007,2008

Powered by phpBB Group © 2001,2005.
 

Create your own free forum | Buy a domain to use with your forum