Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8177141
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 6, 20262026-06-06T23:26:12+00:00 2026-06-06T23:26:12+00:00

I create a CSS for a p tag. I don’t know why font:bold and

  • 0

I create a CSS for a p tag. I don’t know why font:bold and font-size=15 doesn’t work. It means : font in this class doesn’t bold and doesn’t change size although I change number of font-size property. But some other attributes work well, for example : color or text-decoration

Here is short piece of my HTML5 page :

1) CSS Page

<style>
    .title{
        font: bold;
        font-size: 15;
        color: red;
        text-decoration: underline ;
    }
</style> 

2) HTML Page:

<div class="question">
     <p class="title">
         Here is my title
     </p>
</div>

Please help me.

Thanks 🙂

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-06T23:26:13+00:00Added an answer on June 6, 2026 at 11:26 pm

    It’s font-weight and you need to specify a unit for size. Try:

    font-weight: bold;
    font-size: 15px;
    

    jsFiddle example


    Font Size:

    xx-small, x-small, small, medium, large, x-large, xx-large

    A set of absolute size keywords based on the user’s default font size (which is medium). Similar to presentational HTML’s through where the user’s default font size is .

    larger, smaller

    Larger or smaller than the parent element’s font size, by roughly the ratio used to separate the absolute size keywords above.

    length

    A positive length. When the units are specified in em or ex, the size is defined relative to the size of the font on the parent element of the element in question. For example, 0.5em is half the font size of the parent of the current element.

    percentage

    A positive percentage of the parent element’s font size.
    It is best to avoid using values that are not relative to the user’s default font size, such as lengths with units other than em or ex. However, if such values must be used, px are preferred over other units because their meaning does not vary depending on what the operating system thinks (generally incorrectly) the resolution of the monitor is.

    Font Weight:

    normal

    Normal font weight. Same as 400.

    bold

    Bold font weight. Same as 700.

    lighter

    One font weight lighter than the parent element (among the available weights of the font).

    bolder

    One font weight darker than the parent element (among the available weights of the font).

    100, 200, 300, 400, 500, 600, 700, 800, 900

    Numeric font weights for fonts that provide more than just normal and bold. If the exact weight given is unavailable, then 600-900 use the closest available darker weight (or, if there is none, the closest available lighter weight), and 100-500 use the closest available lighter weight (or, if there is none, the closest available darker weight). This means that for fonts that provide only normal and bold, 100-500 are normal, and 600-900 are bold.

    Source: https://developer.mozilla.org/en/CSS/font-size and https://developer.mozilla.org/en/CSS/font-weight

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

i create css code like .inputHide { font-size : 100px; width : 100px; height
everytime i create a div tag and use css there is this little space
I am writing a custom tag to create dynamic css and other html formating
How does one create Dynamic CSS and JavaScript On-The-Fly (using PHP). This needs to
Anyone know if its possible to yet create a css based drop shadow on
I don't know how to title this more accurately. So I have dynamically generated
I'm trying to create css buttons by using the following html markup: <a href=access.php
I'm trying to create a css menu bar that has all grey text with
I am trying to create a css menu. I would like to remove border
I am trying to create a CSS theme switcher button like below. The top

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.