Setting Font Size with SSI Includes

Started by Envy, December 02, 2005, 07:05:26 PM

Previous topic - Next topic

Envy

I did a search for this but couldn't seem to find an answer....

I finally got my SSI.php?ssi_function=recentTopics function to work, but I want to set the font size smaller as it's really really large. I'm assuming I add something in along with the SSI includes part, but I'm not to sure about what or where, or if it has to be in any order or not?

So far I have the straight:
<!--#include virtual="/forums/SSI.php?ssi_function=recentTopics" -->

I would like to make the font 10pt if I could  ::)

kegobeer

I don't think this is possible at all the way you are trying to include SSI.php.  You need to use a PHP file, do a standard include statement for SSI.php, and then call the recentTopics function.  You'll have to return the array instead of merely executing the function, and then write code to display what you want in whatever font size you want.
"The truth of the matter is that you always know the right thing to do. The hard part is doing it." - Norman Schwarzkopf
Posting and you (Click "WATCH THIS MOVIE")

1MileCrash

he's using shtml. he's doing it the correct way in shtml.
The only thing php can't do is tell you how much milk is left in the fridge.



Envy

Aye, using shtml... php made my head hurt hehe. I have two SSI parts on my site, and the second is to display the latest member of the forum, that also showed as large font so I selected it via the Normal view in front page (or selected the spaces that I knew was at) and changed the font... worked for that but it's not working for the top latets posts section.

<span style="font-size: 9pt">&nbsp;<!--#include virtual="/forums/SSI.php?ssi_function=latestMember" --></span>

That's what I have for the latest member... not sure if that's the right way to do it though.

kegobeer

Quote from: Tippmaster on December 02, 2005, 07:39:32 PM
he's using shtml. he's doing it the correct way in shtml.

I know, but like I said, I don't think it's possible unless you use PHP and pull the returned array apart and format it like you want.  The way he's doing it, it's going to be formatted like whatever theme is set for the forum.

A link to the site in question would be helpful.
"The truth of the matter is that you always know the right thing to do. The hard part is doing it." - Norman Schwarzkopf
Posting and you (Click "WATCH THIS MOVIE")

Envy

Site : http://www.wowmb.net/example/index.shtml

I got the "Please welcome xxxxx, our newest member." to be smaller, 9pt font, but I just can't get the other bit too >< I'm sure I was reading somewhere how you can alter it to only show the latest 5 posts, or not show which forum section it was from so I thought I could change font size.  ::)

kegobeer

In your stylesheet, add a class called ssi_table and put your size/font info there.
"The truth of the matter is that you always know the right thing to do. The hard part is doing it." - Norman Schwarzkopf
Posting and you (Click "WATCH THIS MOVIE")

Envy

Okies... does it matter where in the CSS I put it in? I sort of pieced mine together from copying another CSS hehe...

Envy

Don't mind the bit above about only showing the latest 5... got that to work via the SSI.php file...

Now just need to get the font size smaller and I'm good to go  :)

kegobeer

No, it doesn't matter where you put it.  I'd just add it to the end of your stylesheet.  Make sure to do a force refresh on your browser after you make the change.
"The truth of the matter is that you always know the right thing to do. The hard part is doing it." - Norman Schwarzkopf
Posting and you (Click "WATCH THIS MOVIE")

Envy

Put the following at the bottom of the .css file:


ssi_table
{
  font-size : 11px;
  font-family: Verdana
  text-decoration : none;
}


I just followed what ever else was above and made it look the same. Didn't change the page though :-( Although, I think it's because the area that I have the latest posts in is just a table... do I have to somehow name it ssi_table?

psychophat

#11
Hi,

I'm with the same problem but I'm using PHP add the CSS code below and still it's the same output the fonts are still large and color is the same.

Do I need to include a class?

<th height="300" scope="row" class="ssi_tables"><?php ssi_topBoards(); ?></th>

Is it possible to set the font for BOARDS TOPICS POST part and different for the individual boards.

Thank you in advance,

...Message modified... oh I got it working now:

Problem was the >.<ssi_tables forgot to place the .(dot)

.ssi_tables <- added to CSS file found the link on SSI Basic FAQ by Tomer link -> http://www.simplemachines.org/community/index.php?topic=12936.0

Question how do you CSS the lower half of the SSI include?

-Patrick Grey
I adore this forum, from zero PHP knowledge to +.1% per post
I'm going to get the charter member thinggy when I get to save some cash
SMF v.1.1RC2
PHP v.4.3.11

Advertisement: