Facebook button problems

Facebook button problems
0.0 0

#1

Here’s my code for adding a Facebook button to my profile page:

In the HTML -

<button type="social" <i class="fa fa-facebook-official"></i></button>

In the CSS -

<link rel="stylesheet"
href="//maxcdn.bootstrapcdn.com"/font-
awesome/4.5.0/css/font-
awesome.min.css"/>

I’ve looked online and have found a few different methods. Nothing has worked for me. What am I not understanding?

Thank you!


#2

go directly to the font awesome website, click on icons and do a search for facebook… they have 3 different styles. when you click on it…it tells you exactly what you need to put to apply the icon class you need. http://fontawesome.io/icon/facebook/


#3

I’ll try it again. Still not working, although now it’s blue again. I’m going to try playing with the class settings.

Thank you!


#4

Hi! Why is <link rel=“stylesheet"
href=”//maxcdn.bootstrapcdn.com"/font-
awesome/4.5.0/css/font-
awesome.min.css"/> in your css? Can you show your code?


#5

Stefani has a good point, it should be on top of your HTML, not in CSS.

Also, always use latest versions. FontAwesome is currently 4.7.0.


#6

Hi

1.) put the link bellow in the head of your html document

<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">

2.) This is just one option, but it works for me! Just copy/paste it to where you need it and change the link with the link to your page.

<a href="yourfacebooklinkgoeshere" class="btn btn-primary"><i class="fa fa-facebook"></i></a>


#7

I understand now to put it in my HTML. Somehow I got the impression that stuff went into CSS.

Thank you so much for your help. I have success!!

Melanie


#8

Learning here every day. I’m taking good notes, too.

Thank you so much for your help. It’s working now :slight_smile:
Melanie


#9

It’s working!! Thank you so much :slight_smile:
I’ve put it all in my notes, as well, so I can learn from this.

Melanie


#10

I cleaned up your code.
You need to use triple backticks to post code to the forum.
See this post for details.


#11

Thank you!! I appreciate the advice :slight_smile:


#12

No problem, nice to see a fellow lady programmer here :slight_smile:


#13

Yes!! My father and step-mother were both programmers. She is really excited that I’m getting back into it after all these years.