News:

SMF 2.1.4 has been released! Take it for a spin! Read more.

Main Menu

font-size title attachment

Started by Hans Schipper, March 27, 2016, 05:39:59 PM

Previous topic - Next topic

Hans Schipper

Hello,
The font-size of the title of an attachment to a topic in our website (motordocs.nl) is too small. How can the font-size be increased or become colored?
Hans

br360

Take a look at your index.css

Look for-

/* All the signatures used in the forum.  If your forum users use Mozilla, Opera, or Safari, you might add max-height here ;). */
.signature, .attachments
{
width: 98%;
overflow: auto;
clear: right;
padding: 1em 0 3px 0;
border-top: 1px solid #aaa;
line-height: 1.4em;
font-size: 0.85em;
}


Change the font-size from 0.85em; to say something like 1.25em; (or whatever size text you want)

That will also change the font size of your signature text to the same size though, so if you want, you could separate the .signature and the .attachment so it could be something like-

/* All the signatures used in the forum.  If your forum users use Mozilla, Opera, or Safari, you might add max-height here ;). */
.attachments
{
width: 98%;
overflow: auto;
clear: right;
padding: 1em 0 3px 0;
border-top: 1px solid #aaa;
line-height: 1.4em;
font-size: 1.25em;
}
.signature
{
width: 98%;
overflow: auto;
clear: right;
padding: 1em 0 3px 0;
border-top: 1px solid #aaa;
line-height: 1.4em;
font-size: 0.85em;
}

Antechinus

That's a maximally verbose way of doing it. Why not just add .attachments {font-size: 1.25em;} after the default code block? Same effect. Less crud.

Hans Schipper

I did this, but it doesn't work :(

Hans Schipper

Mea Culpa. Pushing the refresh button did it... :)

I didn't understand the exact position of where to add Antechinus' tip.

Hans Schipper

Thank You All for helping me. I have 2 remaining questions:
1. I failed to colour the attachment title with "font-color: blue;" Is this the wrong command?
2. What's the place to be to adjust the font-size of the menu bar (homepage-photoalbums-forum etc)?

Sir Osis of Liver

The attachment title inherits the link color.  You can cheat and fix it inline -

Display.template.php



echo '
<a href="' . $attachment['href'] . '" style="color: red;"><img src="' . $settings['images_url'] . '/icons/clip.gif" align="middle" alt="*" />&nbsp;' . $attachment['name'] . '</a> ';




The font size for main menu buttons is here -

/css/index.css



.dropmenu a span
{
display: block;
padding: 0 0 0 5px;
font-size: 0.9em;
}



Ashes and diamonds, foe and friend,
 we were all equal in the end.

                                     - R. Waters

Antechinus

Better idea, if you're going to hack the template anyway, would be to add a class to those anchors. That way you can have theme-dependent colour easily. So something like:


echo '
<a href="' . $attachment['href'] . '" class="humungous_warthogs"><img src="' . $settings['images_url'] . '/icons/clip.gif" align="middle" alt="*" />&nbsp;' . $attachment['name'] . '</a> ';



Then CSS hex code can be whatever you like, for any theme you are using.

Hans Schipper


Hans Schipper

Our slogan is in sad black. :( I want to fresh it up with a cued color e.g. blue. How is it to be done?

Antechinus


Illori

Quote from: Antechinus on March 30, 2016, 04:55:40 PM
What slogan?

the one in the header? admin -> current theme  Site slogan:
Add your own text for a slogan here. It will replace the SMF logo.

Antechinus

WTF does that have to do with attachments? :D

Illori

Quote from: Antechinus on March 30, 2016, 05:00:48 PM
WTF does that have to do with attachments? :D

nothing that i can tell.

Antechinus

Ah, so he was trying to confuse us. Cunning plan.

Antechinus

Quote from: Hans Schipper on March 30, 2016, 04:01:30 PM
Our slogan is in sad black. :( I want to fresh it up with a cued color e.g. blue. How is it to be done?

Look for the word "slogan" in the css. Change colour there.

Hans Schipper

Sorry for confusing you. Changing the slogan text is not the problem. I did this (see attachy). Bold is okay, but blue doesn't work. So, what the place to be to change website slogan into cued blue?

Antechinus


Hans Schipper


Antechinus


Sir Osis of Liver

Use color: blue;, not font-color: blue;.
Ashes and diamonds, foe and friend,
 we were all equal in the end.

                                     - R. Waters

Hans Schipper

Well, as you can see in my attachment up, I did change color-font there, but it doesn't work. Another slogan spot? I'll check.

Antechinus

The reason it didn't work is because you didn't use valid code. It's pointless asking for advice if you're going to ignore it.

There is no such thing as font-color. It won't work. Do what Sir Osis told you to do.

Use color: blue;

That will work.

Sir Osis of Liver

Would also be helpful if you posted code in code tags.  Screenshots are difficult for us old guys to see.

Ashes and diamonds, foe and friend,
 we were all equal in the end.

                                     - R. Waters

Hans Schipper

Thank you all. It works!
How can code in code tags be posted?
As you noticed, I'm an amateur. I took over mastering our site after our webmaster passed away. There was no info what so ever of how to do what. So far, I managed to resuscitate the website and currently I'm trying to change the outlook. So, hopefully you don't mind me asking questions which are simple to you.
Thankxs again, Hans.

Kindred

code is a BBC (bulletin board code)

[code]...code goes here[/code]
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

Hans Schipper


Advertisement: