Code for the Blogger In You

Scream Binary Cover.

Scream Binary has taught you how to get your website up and running. Now we tell you the blogger, what code you need to know for your future internet stardom.

Wednesday, January 27th, 2010

In “Scream Binary” our online guide to internet publishing, we have taken all the steps to get a blog up and running. Now as a future superstar blogger, we need to get your blog to look the way you want.

There are a couple different ways to achieve the look you want on your blog. If you have the extra cash and know someone good with code, by all means hire a developer to make your site and hold them accountable for all the glitches.

However, if you are lacking the cash flow, the least expensive way comes with an undertaking into the world of code, where you only have yourself to blame and the labor is indentured servant cheap.

Welcome the Code Jungle

Binary is the language that computers use to communicate with each other. Code is the language that computers use to communicate with humans. How do computers translate our words from a series of On and Off switches?

Binary is a Big Bang!

In the beginning there was Binary. Well to be truthful, before there were computing machines, there was code. Even Paul Revere, who might not have made it to the end of his midnight ride, used a Binary like code to know how the Red Coasts where coming.

Binary is a two symbol number system. Meaning there are only two letters in the Binary alphabet, and the letters are 1 and 0. However 1 and 0 do not represent numbers but are two forms of being; on and off, positive and negative, or Mac and Windows.

2 Bit by Sea

The code used for Paul Revers midnight run might have been called a 2 bit binary code. 2 bit for the number of lanterns, or Binary digits. Lanterns have two states of being, they can be lit or not lit, on or off.

So while there were 2 lit lanterns in the Old North Church, which makes us think “2”, a code junkie might think “11”. He wouldn’t even think “2” as in Binary 11 equals 3, but he might think 2 bit Binary code that equals 3.

2 by Land and 3 by Sea?

For our revolutionary example, the “11” code represents that both binary digits are on, positive, or Mac. If the British had traveled by land, then the Binary code would have been “10”, which finally equals 2.

ASCII spells Unity

Many years after the fateful ride of Paul Revere, America moved into the Industrial age and telegraph poles cropped up from coast to coast. As American grew closer to the computer age, a problem of binary interpretation rose.

As we saw in our 2 bit binary code, “11” can mean different things to different types of code. To place the American technological society on the same page, the American National Standards Institute, then the American Standards Association, created the ASCII, or American Standard Code for Information Interchange.

The ASCII is a 7 bit binary code. Meaning there are 7 binary digits in a line of ASCII code. Why 7 binary digits? At the time of ASCII’s inception, the most common real world application was for teleprinters, that could send, receive, and print information.

The industry standard number of bits for teleprinters of the time was about 7.5 bits. Meaning that the teleprinters could only process 7 binary digits at a time.

The ACSII created a universal set of rules for the 7 bit teleprinters. If a user typed “ANF” into their teleprinter, it would interpret “0100000001”, “01001110”, and “01000110”. Then the teleprinter would send the message. The receiving teleprinter would get “0100000001”, “01001110”, and “01000110”, and print “ANF”.

All Code is Not Created Equal

Mac, Windows, and Linux use some version of ACSII to type out code, but the similarities end at the keyboard.

The core code of various Operating Systems are as different as various languages in the world. You can’t speak Spanish unless you learn how, and your Mac can’t speak Windows unless it “learns” how. Why? I could tell you a great story but “Pirates of Silicon Valley” does a way better job*.

HTML Is ASCII For The Internet

When Mac and Windows don’t talk to each other, and Linux is willing but no one wants to, the internet has a big problem. As the binary superhighway, the internet is the gathering place of all types of computers and needs a type of code that all computers can read. HTML, or Hyper Text Markup Language, is the universal language it needed.

Like the ASCII, HTML set the standard code for the entire World Wide Web. However instead of interpreting binary into typeface, HTML applies markup tags to describe a website.

It should be noted that ASCII is no longer the standard, and as of 2008, has been replaced by UTF-8, 8 bit Unicode Transformation Format. HTML has also been mostly replaced by CSS, Cascading Style Sheet.

But CSS is more of the next evolutionary step for HTML and owes it’s base to the hyper text daddy. Most of the code used in your post will be HTML and we will go over a couple of crucial bits of code.

HTML Code For Blogger’s Blog

The post you write will contain two key HTML tags. Think of any web site you go to and think of all the elements you see on most Web pages. What are the two most common HTML Tags you see on most pages? No not porn!

Correction Links and Images

Most post will include at least one instance of both link and image HTML tags. However as everything worth doing, there is the way to write code and the correct way to write link and image tags.

Hyperlinks with Hypertext

Many of us know the HTML code that inserts links into web documents:

<a href="http://www.website.com"> website </a>

But did you know it’s called a Hyperlink and the text in a hyperlink is called the Hypertext? No (and even if you said yes), well then you might not know that two things happen in the Hyperlink above.

The “a” tells us the HTML tag is an anchor tag, and the “href” attribute, or Hypertext REFerence, states where the link goes. The separation of tag and attribute is why the code closes with an “/a” tag and not a “/a href”.

Along with “href”, you can add “title” and “target” attributes to anchor tags to give them real piazzas.

<a title="Read ANF" href="http://www.americannonfiction.com" target="_blank"> American NonFiction</a>

Which will look like this; American NonFiction (hint: scroll mouse over hypertext and click for new window.)

Some Blogging Superstars recommend that all outbound links, link that lead away from your site, should include the “Target” attribute set to “blank”. This will open the link in a new window and keep the visitors connected to your site. Which they say is good for SEO.

Image is IMG

Many of us also know the HTML code that inserts pictures into web documents as:

<img src="http://www.picturesite.com/picture.jpg" alt="picture" />

Like the anchor tag denotes a hyperlink, the “img” tag denotes an image. Most people only use the img tag and the src, or source, attribute.

However to only use the “src” attribute is not perfect or SEO friendly. There is one key attributes to make the img tag really sing with SEO. Add the “alt” attribute to all images to gather bonus points with the SEO Gods.

<img src="/favicon.ico" alt="ANFs favicon" />

Or this ANFs Favicon

(Notice how I didn’t add the webpage name to the src attribute? When your src or href points to its own website, you may omit the http up until the first backslash after the address.

The Wrap up

This is a brief overview of the history and application of HTML code. For a more in-depth look into the ins and outs of HTML, check out W3school’s HTML tutorial. W3school is a great source for free tutorials and information about setting the internet code strait. Also check back with us next time as we dive into the code of CSS.

*Plus Bill Gates won’t sue me this way!

Tags: , ,

POST A COMMENT

Your email is never published nor shared. Required fields are marked *

*
*

Under

Construction

Social Issues Blog Directory