Printable Version of Topic

Click here to view this topic in its original format

HTMLHelp Forums _ Markup (HTML, XHTML, XML) _ How to link my social media with this code?

Posted by: boomercates Sep 22 2020, 08:24 PM

Where do i insert my links and how to make my social media link?
Thanks in Advance!

<!DOCTYPE html>
<center>
<html>
<head>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
<style>
.fa {
padding: 20px;
font-size: 30px;
width: 50px;
text-align: center;
text-decoration: none;
margin: 5px 2px;
}

.fa:hover {
opacity: 0.7;
}

.fa-facebook {
background: #3B5998;
color: white;

}

.fa-instagram {
background: #a3137c;
color: white;

}

.fa-snapchat-ghost {
background: #fffc00;
color: white;
text-shadow: -1px 0 black, 0 1px black, 1px 0 black, 0 -1px black;
}
</style>
</head>
<body>


<!-- Add font awesome icons -->
<a href="#" class="fa fa-facebook"> <a href="https://www.facebook.com/boomercates/"></a>
<a href="#" class="fa fa-instagram"></a>
<a href="#" class="fa fa-snapchat-ghost"></a>



</center>
</body>
</html>

Posted by: Christian J Sep 23 2020, 06:08 AM

You already have a Facebook link at the end, however you can't nest links inside each other.

See also https://htmlhelp.com/faq/html/links.html#link-howto

Posted by: pandy Sep 23 2020, 07:36 AM

I think that all is the sample code/markup that is supposed to be used. Is that right?

If so you need to pick the bits you need out and put them in your own page.

The LINK (ajax stuff) goes in HEAD. The CSS goes in your own style sheet and the links (A tags) go where you want them in BODY (after you have fixed the nested links Christian pointed out).

IF what you posted is something you actually use as it is, that CENTER tag can't be there above the start tag for HTML.


Powered by Invision Power Board (http://www.invisionboard.com)
© Invision Power Services (http://www.invisionpower.com)