Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

"Tag" font size

Status
Not open for further replies.

snowboardr

Programmer
Feb 22, 2002
1,401
PH
Whats the best way to do the font sizing for tags ie, the size related to how many records are under that particular tag or record...

Jason

Jason

[red]Army[/red] : [white]Combat Engineer[/white] : [blue]21B[/blue]

 
I didn't get any part of the question from above...Can you provide more info on what you are asking?

Sharing the best from my side...

--Prashant--
 
This all is done using CSS. Create CSS classes and apply those classes as per the requirements in your code.
Few days ago, there was one info thread given on some useful links for CSS tools. check it out at CSS Tools. I think this may give you some idea.

Sharing the best from my side...

--Prashant--
 
I know how to do the css stuff, I just don't know the best way to calculate the font size based on post avgs etc... I just need an example of the math to do it...

Jason

Jason

[red]Army[/red] : [white]Combat Engineer[/white] : [blue]21B[/blue]

 
Just basic decision branching.
Code:
<%
if postcount < 10 then
   classname = "style10"
elseif postcount > 10 and postcount < 20 then 
   classname = "style20"
elseif postcount > 20 and postcount < 30 then 

' and so on 
else 
   classname = "style_default"
end if
%>

<span class="<%=classname%>">Thread title goes here </span>

Obviously make it into a function to cut down the redundant code.

Chris.

Indifference will be the downfall of mankind, but who cares?
Woo Hoo! the cobblers kids get new shoes.
People Counting Systems

So long, and thanks for all the fish.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top