News:

Bored?  Looking to kill some time?  Want to chat with other SMF users?  Join us in IRC chat or Discord

Main Menu

Trouble changing font size, inline, in the index.template file

Started by rcane, July 06, 2022, 12:03:15 PM

Previous topic - Next topic

rcane

Good morning,

I added a few bits of information in the index.template (right above unread posts since last visit) so a member can see it right up front when they log in.   

I can change the weight to bold on the list items ( <li> ), but I'm not having luck changing font size or color. 


This is the syntax I was using: 

<li style="font-weight: bold", "font-size:50px">blah blah words</li>

I've tried with "," and ";" after the bold attribute with no success.

Thoughts?

Doug Heffernan

#1
Quote from: rcane on July 06, 2022, 12:03:15 PMThis is the syntax I was using: 

<li style="font-weight: bold", "font-size:50px">blah blah words</li>

Try this:

<li style="font-weight: bold; font-size: 50px">blah blah words</li>
Instead of hardcoding it like this, you can also create a class at the css file and use that instead. Hope it helps.




rcane

Quote from: Doug Heffernan on July 06, 2022, 12:08:41 PM
Quote from: rcane on July 06, 2022, 12:03:15 PMThis is the syntax I was using: 

<li style="font-weight: bold", "font-size:50px">blah blah words</li>

Try this:

<li style="font-weight: bold; font-size: 50px">blah blah words</li>
Instead of hardcoding it like this, you can also create a style at the css file and use that instead. Hope it helps.






I'll try that.  thanks.  I didn't want to go the sheet-way since it was just one or two lines. 



*** yep, I just didn't encapsulate the entirety within the quotations.  thank you very much. 

Doug Heffernan

Quote from: rcane on July 06, 2022, 12:12:33 PM*** yep, I just didn't encapsulate the entirety within the quotations.  thank you very much. 

You are welcome. Glad to have been of help.

Advertisement: