Simple HTML and PHP but I can't get it! Need some help here...

7 replies
Hello WF Programmers,

I would like to insert a headline, so I edited the home.php. However, I wonder why this html tag <font face="Century Gothic" color="#0b2b40" size="6"> won't take effect.

This is the complete html line:

<font face="Century Gothic" color="#0b2b40" size="6"><strong>Finally, There Is Hope For The Millions Who Suffer From Acne!</strong></font>

The headline text appears but the size is not that big.

Do I need to add a php code first before inserting html tags?

Any information you may provide will be highly appreciated.

Thank you.

G.B.
#html #php #simple
  • Profile picture of the author magiclouie
    Can you try removing the size attribute, size="6" , instead add the header tags like <h1> text here </h1> , <h2> text here </h2> , etc
    {{ DiscussionBoard.errors[6298616].message }}
  • Profile picture of the author TheApex
    You can try size="7" - and get a bigger font
    or... using some CSS, and you get something like this:

    Code:
    <font face="Century Gothic" color="#0b2b40" style="font-size: 20px;"><strong>Finally, There Is Hope For The Millions Who Suffer From Acne!</strong></font>
    Just change the 20px to any size you want.
    {{ DiscussionBoard.errors[6299470].message }}
  • Profile picture of the author OldLodgeSkins
    Hi,

    I'd start by not using deprecated methods if I were you... Write it in CSS instead. Nowadays you just can't separate HTML and CSS. Should look like this (I haven't tested this I'm just writing it quickly):

    Code:
    <span style="font-family:Century Gothic,Arial; Color:#0b2b40; font-size: 12px; font-weight: bold;">Finally, There Is Hope For The Millions Who  Suffer From Acne!</span>
    I'm not sure everyone has that font you've chosen so it's best to define a substitute like I have done above.

    Seb.
    Signature
    Do you use Facebook ? Then you can make money just by inviting people to a Facebook group ! It's called the Instant Income System. How cool is that?
    {{ DiscussionBoard.errors[6301092].message }}
  • Profile picture of the author flashisland
    Better yet if it's a headline, you should be using headline tags as well:

    Code:
    <h1 style="font-family:"Century Gothic",Arial; color:#0b2b40; font-size: 12px;">Finally, There Is Hope For The Millions Who  Suffer From Acne!</h1>
    PHP shouldn't have anything to do with it. Just make sure it's not inside a PHP tag!
    {{ DiscussionBoard.errors[6301407].message }}
  • Profile picture of the author kayetaylor
    magiclouie is right try to make you headline in <h1> tag don't forget to close your tag </h1>

    <h1>Finally, There Is Hope For The Millions Who Suffer From Acne!</h1>
    {{ DiscussionBoard.errors[6302247].message }}
  • Profile picture of the author Go4DBest
    Thanks a lot for your inputs. I tried them all and they work like a charm.

    You simply are the best.
    Signature
    We setup and design wordpress sites using the Divi theme for roughly 200 USD. Let's talk.
    {{ DiscussionBoard.errors[6304096].message }}
  • Profile picture of the author nbatioco
    Originally Posted by Go4DBest View Post

    Hello WF Programmers,

    I would like to insert a headline, so I edited the home.php. However, I wonder why this html tag <font face="Century Gothic" color="#0b2b40" size="6"> won't take effect.

    This is the complete html line:

    <font face="Century Gothic" color="#0b2b40" size="6"><strong>Finally, There Is Hope For The Millions Who Suffer From Acne!</strong></font>

    The headline text appears but the size is not that big.

    Do I need to add a php code first before inserting html tags?

    Any information you may provide will be highly appreciated.

    Thank you.

    G.B.

    You can change it size by changing your html code (size="6") to any value.. and dont forget to add px because other browser might see your code as conflict.

    For example, if you want to create a bigger font size, just change (size="6") to size="24px"

    You all set.
    {{ DiscussionBoard.errors[6311295].message }}

Trending Topics