andrew covell's profile picture

Published by

published
updated

Category: Web, HTML, Tech

HTML codes i commonly use

i've blogged a few codes i commonly use on the site for various different reasons this post exzist to trim down my bookmarks however i can also see this being useful for someone new to the site


hyperlink
<a href="YourLinkHere.com">insert your text here</a>
image hyperlink
  1. <a href=”thelink”> 
  2. <img src=”imageurl” alt=”backuptext" style=” width:200px ; height:auto ; border=0;”>  
  3. </a>  

The alt attribute provides an alternate text for an image, if the user for some reason cannot view it. It's optional though.

You can style the image by style Attribute. You can change image width, height and add border. But its also optional.


transparancy

<style>

body{

  background-color: ;

  opacity: 0.5;

  background-image:  linear-gradient(transparent 25%), linear-gradient(transparent 25%), linear-gradient(transparent 25%);

  background-position:  19px 0, 19px 0, 0 0, 0 0;

  background-size: 38px 38px;

  background-repeat: repeat;

}

</style>

i'm not quite sure how it works so there's likely a lot of unnecessary code in it you can also use it for a solid color background however if you leave the color blank you can use gif or img background behind it instead this does not work on bulletins 


gif background
 <style>
body{
    background-image: url('img url');
    background-size: cover;
    
    
    
    height: 100vh;
    padding:0;
    margin:0;
} </style>
i use this as an all purpose however this doesn't work on bulletins for that you'll have to use the image background code which does not support gifs like this code does
image background
<style> body {background-image: url('imageadress.com.jpeg');background-attachment: fixed;background-repeat: no-repeat;background-size: cover;} </style>

image and gifs
<img src="imagelink">


slide show

<marquee>
content
</marquee>

(replace content with words or code to get a slide show of whatever content is placed between the tag)

text color
<font color="color_name|hex_number|rgb_number">
mouse pointer

<style>body { cursor: url('imagelink'), auto; }</style>

this is a picky code i have a collection on deviantart with images that should work


63 Kudos

Comments

Displaying 4 of 4 comments ( View all | Add Comment )

Ash_fishstickz3

Ash_fishstickz3's profile picture

OMG! thankz sm >.<


Report Comment

rexxu ルビー

rexxu ルビー's profile picture

tysmm


Report Comment

♥ King Julien ♥

 ♥ King Julien ♥ 's profile picture

I cant get the code for the cusor to worl for me, heeelppp!!


Report Comment



hmm not sure theres a few possibilities as to why it's not working the 2 that come to my mind is A.) the image is too big (like i said this code is very picky) or B.) this code exists further down your script with either a bad image URL or no image URL over wrighting the code you've inserted further up the lines

by andrew covell; ; Report

When you use the image link, don't click the domain link on the top! Instead right click the actual picture's address link and paste that. Hope this helps :]

by βαmβαmSησσz; ; Report

SafeInSanity

SafeInSanity's profile picture

How did you add those codes here without them producing the html results?


Report Comment



i left the mode on WYSIWYG when i typed them out

by andrew covell; ; Report

Wow, interesting. Very cool!

by SafeInSanity; ; Report