<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Echo Enduring Blog &#187; coding</title>
	<atom:link href="http://blog.echoenduring.com/tag/coding/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.echoenduring.com</link>
	<description>Just another WordPress weblog</description>
	<lastBuildDate>Thu, 09 Sep 2010 03:02:40 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<item>
		<title>More Thoughts on Language and Coding for the Web</title>
		<link>http://blog.echoenduring.com/2010/03/09/more-thoughts-on-language-and-coding-for-the-web/</link>
		<comments>http://blog.echoenduring.com/2010/03/09/more-thoughts-on-language-and-coding-for-the-web/#comments</comments>
		<pubDate>Wed, 10 Mar 2010 03:44:12 +0000</pubDate>
		<dc:creator>Matt Ward</dc:creator>
				<category><![CDATA[Articles]]></category>
		<category><![CDATA[coding]]></category>
		<category><![CDATA[language]]></category>
		<category><![CDATA[web]]></category>

		<guid isPermaLink="false">http://blog.echoenduring.com/?p=2757</guid>
		<description><![CDATA[In this second article on the relationship between human languages and coding for the web, I will consider issues of linguistic evolution, language families, syntax and the way all of these things relate to coding for the web. I will also make a bold suggestion about your ability to code, even if you've never written a single line in your life! <p><h3>Exclusive Content</h3>

<p>To thank you for subscribing to my feed, I am including exclusive, feed-only content for you at the bottom of each post!</p>

<p><strong>Current Freebie Code</strong> - 7ev165dd</p>


</p>
]]></description>
			<content:encoded><![CDATA[<div class="tweetmeme_button" style="float: right; margin-left: 10px;">
			<a href="http://api.tweetmeme.com/share?url=http%3A%2F%2Fblog.echoenduring.com%2F2010%2F03%2F09%2Fmore-thoughts-on-language-and-coding-for-the-web%2F"><br />
				<img src="http://api.tweetmeme.com/imagebutton.gif?url=http%3A%2F%2Fblog.echoenduring.com%2F2010%2F03%2F09%2Fmore-thoughts-on-language-and-coding-for-the-web%2F&amp;source=echoenduring&amp;style=normal&amp;service=bit.ly" height="61" width="50" /><br />
			</a>
		</div>
<p>Last week, I penned a substantial article titled &#8220;<a href="http://blog.echoenduring.com/2010/03/05/language-and-metaphor-an-alternate-view-on-coding-for-the-web/">Language and Metaphor: An Alternate View on Coding for the Web</a>&#8220;, in which I discussed the various web languages and suggested that they all fall under one of four different categories – descriptive (HTML, XML), sensory (CSS), procedural (JavaScript, PHP) and request (SQL). </p>
<p>That was the first of a two part series on language and coding. This article is part two.</p>
<div id="attachment_2762" class="wp-caption aligncenter" style="width: 510px"><img src="http://blog.echoenduring.com/wp-content/uploads/2010/03/language-and-coding.jpg" alt="More Thoughts on Language and Coding for the Web" title="More Thoughts on Language and Coding for the Web" width="500" height="500" class="size-full wp-image-2762" /><p class="wp-caption-text">More Thoughts on Language and Coding for the Web</p></div>
<p>The specific direction of this article is a little less focused. Though I will ultimately come to a final conclusion, I would mostly like to consider coding as it relates to human (or &#8220;natural&#8221;) languages in several areas. First, I would like to look at the evolution of language, and the way different languages can be grouped into families. Then, I will consider the importance of syntax and grammar and the linguistic base of every coding language that I know of.</p>
<p>This will, admittedly, be a somewhat general discussion, but I think and hope that you may find it interesting. </p>
<p><span id="more-2757"></span></p>
<h3>The Evolution of Language</h3>
<p>Human languages do not exist in a vacuum. Nor have any of them simply sprung out of nothingness fully formed and ready to be written or spoken by the masses. Instead, languages change and evolve. Often, they even collide, creating hybrid dialects which may go on to become new languages all on their own. </p>
<p>Take <a href="http://en.wikipedia.org/wiki/History_of_the_English_language">English</a>, for example. Though I am simplifying somewhat, English began as the language of the Anglo-Saxons who invaded the British Isles in the late 5th century. It was primarily Germanic in origin, and eventually evolved into what is known today as Old English, which very few of today&#8217;s English speaking people could read without extensive study. </p>
<p>Later, English would be transformed again by contact with the Norse, and through the Norman conquest, which would infuse the language with a great deal of French-influenced words. As such, the language that we have today actually has several linguistic ancestors, and is related to other languages like French and (to a lesser extent) German. </p>
<p>Coding languages are much the same. HTML was developed from an older language markup language called <a href="http://en.wikipedia.org/wiki/SGML">SGML</a>, which was in turn a standardized version of an older language called <a href="http://en.wikipedia.org/wiki/IBM_Generalized_Markup_Language">GML</a>. In turn, HTML has also been extended in multiple versions (including the new HTML 5) and into XHTML. </p>
<p>Similarly, while languages like PHP, Perl and JavaScript are all vary from each other and serve vastly different purposes, they also share a common programmatic ancestor in the <a href="http://en.wikipedia.org/wiki/C_%28programming_language%29">C language</a>.</p>
<h3>All in the Family</h3>
<p>In a sense then, we can think of each of the four different types of coding languages that we looked at in the previous post as language families, within which the specific languages are all related to each other in some way. There are even some relations between families. PHP is a good example of this. While, at its core, it is a procedural programing language, it is also designed to integrate with blocks of HTML code, making it an ideal for serving up dynamically generated web pages.</p>
<p>All of these relationships can actually be a real advantage for would be coders, because it means that when you move from one language to another, you don&#8217;t necessarily have to learn everything from scratch. PHP, Perl and JavaScript all use a basic C syntax, which means that someone who is familiar with one will have a reasonable level of comfort when transitioning to another. Similarly, if you know HTML, moving to XHTML is fundamentally a matter of learning which tags have been deprecated and how to tighten up the code to make it validate according to the stricter XML specifications. </p>
<div id="attachment_2766" class="wp-caption aligncenter" style="width: 510px"><img src="http://blog.echoenduring.com/wp-content/uploads/2010/03/language-books.jpg" alt="Many human languages are more closely related than we might think" title="Many human languages are more closely related than we might think" width="500" height="175" class="size-full wp-image-2766" /><p class="wp-caption-text">Many human languages are more closely related than we might think</p></div>
<p>To continue with our linguistic metaphors, it&#8217;s kind of like learning a sister language to one that you already know. Both French and Spanish ultimately derived from Latin, and I have often heard that if you know one, learning the other is relatively easy. While I don&#8217;t know very much Spanish, I did take one Latin class at university, and found that my fluency in French really helped. Most of the other students in the class were Classics majors (I was in the English program), and had little training in French (other than the high school classes that all Canadian students are required to take). Because I had been speaking French since I was six years old, though, I seemed to pick up the ancient Roman language more quickly, because I could relate it back to a something that I already knew. </p>
<p>When the semester was over, I decided that Latin was not something that I really wanted to pursue, but still ended up with one of the highest marks in the class. If it had not been for my background in French, though, I&#8217;m not sure that I would have been quite so successful. </p>
<p>Regardless, the point that I am trying to make here is that learning to code in multiple languages (HTML and XML, for example, or JavaScript and PHP) is not necessarily a matter of learning each one from scratch. Much of what you learn from one language can actually help inform what you need to know for another language.</p>
<p>Of course, this is especially true of different languages within the same basic family. If you learn the basic concepts of programming – defining variables, defining conditional statements, writing custom functions and such – what you learn can be generally applied from one programming language to another, from C to PHP, and even to Basic-based languages like Visual Basic. The key differences are found mostly in the names of various commands and functions, and (often slight) variations in basic syntax.</p>
<h3>Syntax and Grammar</h3>
<p>Syntax is important too, and the concept comes directly from the field of linguistics itself, where syntax is used to describe the formation of sentences – either written or spoken. At its most basic level, then, syntax is about word order, punctuation and the other rules of grammar, and varies from language to language. </p>
<p>A simple example is the difference between the use of adjectives in English and French. In English, adjectives almost always precede nouns, as in the example:</p>
<blockquote><p>The <i>large</i>, <i>red</i> tree&#8230;</p></blockquote>
<p>In French, however, it is common to see adjectives come after the noun as in</p>
<blockquote><p>Le <i>grand</i> arbre <i>rouge</i>&#8230;</p></blockquote>
<p>If we were to try to use the exact same French syntax in English, the sentence would read:</p>
<blockquote><p>The large tree red&#8230;</p></blockquote>
<p>And that&#8217;s a sentence that even Yoda wouldn&#8217;t use. So, as you can see, syntax is important for conveying meaning in language. </p>
<p>It is doubly so with coding. Computers are very powerful when it comes to processing raw data, but they&#8217;re really not all that smart. While bad grammar can make something difficult to read, in most cases the human mind is smart enough to be able to fill in the gaps and actually figure out what is being said. Again, Yoda is a prime example. The Jedi master might say something like:</p>
<blockquote><p>Changes nothing this does.</p></blockquote>
<p>This is not a proper sentence in English, but most people who hear (or read) it will be able to translate the sentence and understand that it is actually saying:</p>
<blockquote><p>This changes nothing.</p></blockquote>
<p>Computers don&#8217;t usually work this way, which means that you need to be much more exact with your syntax. For example, in JavaScript you would declare a variable like this:</p>
<p><code>var myName = “Matt”;</code></p>
<p>This command will be understood and executed by the interpreter. However, something like this will throw an error:</p>
<p><code>Variable myName is Matt.</code></p>
<p>As humans, we are able to recognize that these two commands are saying pretty much the same thing, but when it comes to coding “pretty much” might as well be “completely wrong”. The computer is expecting very specific commands that follow very specific rules. Any deviation from those rules will inevitably cause problems. </p>
<p>Fortunately, the syntax for coding languages tends to be far simpler than the grammar for a spoken language like English. There are typically a few simple rules for structuring your code, most of which are usually fairly simple to learn. There are few (if any) exceptions to these rules, too, unlike English which has at least a dozen ways of breaking any given grammatical rule. </p>
<div id="attachment_2768" class="wp-caption aligncenter" style="width: 510px"><img src="http://blog.echoenduring.com/wp-content/uploads/2010/03/typing.jpg" alt="I would suggest that if you can read and write, you can also code" title="I would suggest that if you can read and write, you can also code" width="500" height="175" class="size-full wp-image-2768" /><p class="wp-caption-text">I would suggest that if you can read and write, you can also code</p></div>
<p>This makes learning a coding language much simpler than learning another spoken language. In fact, I would like to suggest that anyone who can read and write can (with some commitment) also learn to code!</p>
<p>Seriously.</p>
<p>In truth, all “coding” is simply writing a series of instructions or schematics to be interpreted by the computer. If you can write basic instructions in English, or describe the various elements of a given object, I am confident that you would also be able to write code. All you need to do is learn the language and its syntax.</p>
<h3>Based on English</h3>
<p>Despite the fact that looking at a few lines of JavaScript can be as inaccessible to a non-coder as a few lines of Old English, the fact remains that every single major programming that I know of is actually based on English, which can make it a lot easier for English speaking people to pick up these coding languages.</p>
<p>If you understand the meaning of words like if, else, loop, for and while, then you will already have a solid grasp on many of the commands used to control loops and conditional statements in most languages. Similarly, functions like JavaScript&#8217;s alert(), prompt() and confirm() are all relatively self-explanatory, based simply on their names.</p>
<p>The same is also true of HTML, with tags like &lt;title&gt;, &lt;blockquote&gt; and &lt;cite&gt;, or for CSS properties like background-position, line-height or font-weight, which literally describe the properties that they control </p>
<h3>The Masters&#8230; and the Rest of Us</h3>
<p>Of course, while I do believe anyone who can write can also code, I don&#8217;t necessarily believe that everyone can really master the art. The vast majority of people in Western countries can read and write. In my opinion, far fewer can actually write well, and only a very rare few are what I would call masters of the language – those individuals who can weave their words with such poise and beauty as to be able to truly affect the hearts of their readers.</p>
<p>I think the same thing is true of coding. While I believe that any designer can develop into a competent coder, I don&#8217;t necessarily think that all of these people will necessarily be good coders. Moreover, only a very few will ever become the type of truly great coder who is capable the pure creativity and innovation that truly moves the internet forward.</p>
<p>Those coders are the Shakespeares, Hemingways and Hardys of this great digital playground we call the World Wide Web. Many of us designers and developers look up to them, perhaps with the hope of one day achieving a similar status. Until then, the rest of us can just keep learning and pushing forward, and getting a little better with every single day. </p>
<p><strong>What are your thoughts? How do you relate the concepts of language and coding for the web? I&#8217;d love to hear your thoughts on this, so please feel free to leave a comment!</strong></p>
<div id="crp_related"><div class="grid_12"><h2>Related Posts</h2></div><div class="grid_3 post"><h3><a href="http://blog.echoenduring.com/2010/03/05/language-and-metaphor-an-alternate-view-on-coding-for-the-web/" rel="bookmark" class="crp_title">Language and Metaphor: An Alternate View on Coding for the Web</a></h3><p class="posted">posted on <span>Mar 5, 2010</span>.</p><p class="crp_excerpt"> Coding websites is often thought of as being a highly technical craft, but that fact remains that the foundation of all coding is the languages that are used to do it. In this first post in a two part series, we are going to take a different view of coding for the web, by looking at various coding languages as they relate to actual, human language.</p></div><div class="grid_3 post"><h3><a href="http://blog.echoenduring.com/2010/08/29/considering-an-xhtml5-methodology/" rel="bookmark" class="crp_title">Considering an (x)HTML5 Methodology</a></h3><p class="posted">posted on <span>Aug 29, 2010</span>.</p><p class="crp_excerpt"> In this article, I will be offering my own perspective on HTML5, my concerns about its openness in terms for formatting, and the benefits of XML syntax. All of this will bring us to the simple formulation of an (x)HTML5 methodology for readable, well written code as we move forward.  </p></div><div class="grid_3 post"><h3><a href="http://blog.echoenduring.com/2010/03/02/should-designers-know-how-to-code-thoughts-from-a-developer/" rel="bookmark" class="crp_title">Should Designers Know How to Code? Thoughts From a Developer</a></h3><p class="posted">posted on <span>Mar 2, 2010</span>.</p><p class="crp_excerpt"> Should designers be able to code? That's a big question that has been debated quite heatedly in recent weeks. In this post, guest author and developer Amber Weinberg weighs in with her own views on the subject, based on her own extensive experience coding her clients' designs.</p></div><div class="grid_3 post"><h3><a href="http://blog.echoenduring.com/2009/08/23/echoes-week-1/" rel="bookmark" class="crp_title">Echoes &#8211; Week 1 (Aug 23, 2009)</a></h3><p class="posted">posted on <span>Aug 23, 2009</span>.</p><p class="crp_excerpt"> Echoes: Week 1 - August 23, 2009. This is the first edition of my weekly Echoes posts, in which I feature some of the best work that I have found on the web. Features one logo, one piece of art, one tutorial and one website.</p></div></div><p><h3>Exclusive Content</h3>

<p>To thank you for subscribing to my feed, I am including exclusive, feed-only content for you at the bottom of each post!</p>

<p><strong>Current Freebie Code</strong> - 7ev165dd</p>


</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.echoenduring.com/2010/03/09/more-thoughts-on-language-and-coding-for-the-web/feed/</wfw:commentRss>
		<slash:comments>8</slash:comments>
		</item>
		<item>
		<title>Language and Metaphor: An Alternate View on Coding for the Web</title>
		<link>http://blog.echoenduring.com/2010/03/05/language-and-metaphor-an-alternate-view-on-coding-for-the-web/</link>
		<comments>http://blog.echoenduring.com/2010/03/05/language-and-metaphor-an-alternate-view-on-coding-for-the-web/#comments</comments>
		<pubDate>Fri, 05 Mar 2010 05:38:18 +0000</pubDate>
		<dc:creator>Matt Ward</dc:creator>
				<category><![CDATA[Articles]]></category>
		<category><![CDATA[coding]]></category>
		<category><![CDATA[CSS]]></category>
		<category><![CDATA[html]]></category>
		<category><![CDATA[language]]></category>

		<guid isPermaLink="false">http://blog.echoenduring.com/?p=2704</guid>
		<description><![CDATA[Coding websites is often thought of as being a highly technical craft, but that fact remains that the foundation of all coding is the languages that are used to do it. In this first post in a two part series, we are going to take a different view of coding for the web, by looking at various coding languages as they relate to actual, human language.<p><h3>Exclusive Content</h3>

<p>To thank you for subscribing to my feed, I am including exclusive, feed-only content for you at the bottom of each post!</p>

<p><strong>Current Freebie Code</strong> - 7ev165dd</p>


</p>
]]></description>
			<content:encoded><![CDATA[<div class="tweetmeme_button" style="float: right; margin-left: 10px;">
			<a href="http://api.tweetmeme.com/share?url=http%3A%2F%2Fblog.echoenduring.com%2F2010%2F03%2F05%2Flanguage-and-metaphor-an-alternate-view-on-coding-for-the-web%2F"><br />
				<img src="http://api.tweetmeme.com/imagebutton.gif?url=http%3A%2F%2Fblog.echoenduring.com%2F2010%2F03%2F05%2Flanguage-and-metaphor-an-alternate-view-on-coding-for-the-web%2F&amp;source=echoenduring&amp;style=normal&amp;service=bit.ly" height="61" width="50" /><br />
			</a>
		</div>
<p>Earlier this week, I posted an article by Amber Weinberg, entitled “<a href="http://blog.echoenduring.com/2010/03/02/should-designers-know-how-to-code-thoughts-from-a-developer/">Should Designers Know How to Code? Thoughts From a Developer</a>.” In that article, Amber writes about her own experiences as a front-end developer and comes to the basic conclusion that, while not all designers actually need to code their designs, they should understand the basics of what is and is not possible (or at least desirable) when it comes to web design.</p>
<div id="attachment_2713" class="wp-caption aligncenter" style="width: 510px"><img src="http://blog.echoenduring.com/wp-content/uploads/2010/03/language-and-metaphor.jpg" alt="Language and Metaphor: An Alternate View on Coding for the Web" title="Language and Metaphor: An Alternate View on Coding for the Web" width="500" height="500" class="size-full wp-image-2713" /><p class="wp-caption-text">Language and Metaphor: An Alternate View on Coding for the Web</p></div>
<p>She also notes that coding “is another language.” As a designer with a background in literature, this just added fuel to something that I had already been thinking about: namely the idea of how coding languages like HTML, CSS or JavaScript are related to human languages like English.</p>
<p>I&#8217;m no master coder, but I&#8217;ve been working on websites for well over 10 years now, and in my experience there are essentially four types of languages at work on the internet (both font-end and back-end). These include mark-up, style sheets, programming and database queries. Each type of language has a different general purpose, which is actually reflected in its general syntax and structure. In this article, which will be the first in a two part series, I want to look at these four types of coding languages, and consider their purposes through various metaphorical comparisons to human (written/spoken) language. </p>
<p><span id="more-2704"></span></p>
<h3>Some Thoughts on Language</h3>
<p>First, though, I would like to consider the more general purpose of all languages, which is to communicate. For the purpose of this article, I have a series of ideas that I want to present to you, my readers. To do so, I carefully select strings of words and punctuation with which to form sentences. These sentences then form paragraphs. As you read, you recognize the words, then the combination of words, the sentences and so on. As you recognize, you interpret and as you interpret, you derive meaning. </p>
<p>If the language is used properly (and I hope that it is), the message that I want to convey is delivered from me to you. </p>
<p>This is the fundamental purpose of all language, and the various coding languages that we are going to look at are really no different. Each exists to communicate some message from one entity to another. The differences emerge in the form of what those entities are, and the message that is being communicated.</p>
<h3>Mark Up – Descriptive Language</h3>
<p>Let&#8217;s start with the granddaddy of all web language types: mark-up. The most common form of mark-up has to be HTML, in its various forms and derivatives. That&#8217;s where I started with coding for the web, and I&#8217;d say it&#8217;s a pretty safe bet to say that it&#8217;s where almost every other web developer started too. Other forms of mark up include XML, or the hybridized XHTML, which is essentially just HTML that conforms to the more rigid syntactical rules of XML. </p>
<div id="attachment_2716" class="wp-caption aligncenter" style="width: 510px"><img src="http://blog.echoenduring.com/wp-content/uploads/2010/03/mark-up.jpg" alt="HTML is probably the most well known form of mark-up" title="HTML is probably the most well known form of mark-up" width="500" height="175" class="size-full wp-image-2716" /><p class="wp-caption-text">HTML is probably the most well known form of mark-up</p></div>
<p>Regardless of what specification we&#8217;re talking about, though, the purpose of all markup – in it&#8217;s purest form – is simply to describe content. A document is marked up with various tags, which should do nothing more than indicate the purpose of each part of the document. Consider this simple example.</p>
<p><code><br />
&lt;h2&gt;Introducing &lt;i&gt;The Second Dive&lt;/i&gt;&lt;/h2&gt;</p>
<p>&lt;p&gt;&lt;i&gt;The Second Dive&lt;/i&gt; is a completely fictional novel that I have made up to write this simple paragraph about. There may actually be a novel titled &lt;i&gt;The Second Dive&lt;/i&gt;, but I have never heard of it, so I am just going to write this out for a few more words. Now it is finished&lt;/p&gt;<br />
</code></p>
<p>What we have here is just some really basic HTML (without the proper document tags, of course). First, we define a second level heading with the &lt;h2&gt; tags (opening and closing). Everything that falls between these tags is considered a second level heading. Next, we define a single paragraph using the &lt;p&gt; tags. Again, everything between those tags is considered to be a single paragraph. </p>
<p>You will also notice that I&#8217;ve used the &lt;i&gt; tag, which indicates that its contents should be italic. I&#8217;ve done this because it is proper to set the title of any novel, film, play or other “long” work in italics. I&#8217;ve also done it because it gives me a great excuse to talk about description versus formatting. </p>
<p>Remember, mark-up is a descriptive language, and each tag is like a different description. We could also use the &lt;cite&gt; or &lt;em&gt; tag to make something appear in italics, but those tags have different meanings than the &lt;i&gt; tag. The &lt;em&gt; tag is basically saying that there should be emphasis placed on its content. Conversely, the &lt;cite&gt; tag defines its content as the citation for a quote. </p>
<p>Neither of these apply to our title. We don&#8217;t want the title to be emphasized, and it&#8217;s not quite a citation either. As such, the &lt;i&gt; tag likely provides the best description for the title of our fictional book. Since mark-up is all about describing our content, then, the &lt;i&gt; tag is clearly the best choice!</p>
<h3>Styles – Sensory Language</h3>
<p>If mark-up is basic descriptive language, style sheet languages like CSS (Cascading Style Sheets) are the sensory language that gives life to that description. As such, it is an add-on type of language, that expands the description of a given element.</p>
<p>I like to think of it like this. Mark up is like a noun, which literally states what something is. For instance, I can point to an object and state that it is a car. In doing so, I have described what it is, and (if you&#8217;ll allow me to extend the metaphor) “marked it up”.</p>
<div id="attachment_2718" class="wp-caption aligncenter" style="width: 510px"><img src="http://blog.echoenduring.com/wp-content/uploads/2010/03/style-sheets.jpg" alt="CSS adds on to the structure created by HTML mark-up" title="CSS adds on to the structure created by HTML mark-up" width="500" height="175" class="size-full wp-image-2718" /><p class="wp-caption-text">CSS adds on to the structure created by HTML mark-up</p></div>
<p>Styles, however, are more like adjectives, which add extra values or properties to the noun. Now, if I point to the same object and state that it is a large, red car, the basic understanding of what the object is doesn&#8217;t change – it is still a car. However, we also have additional descriptive information that tells us that it is large and red. </p>
<p>We can think of styles in much the same way. They hook into HTML and add in various bits of information (predominantly for visual rendering) that exist independently of the mark-up itself. For example, this following rule would add extra information to the second level heading from the our HTML sample:</p>
<p><code><br />
h2{<br />
&nbsp;&nbsp;color: red;<br />
&nbsp;&nbsp;font-size: 1.3em;<br />
&nbsp;&nbsp;font-weight: bold;<br />
}<br />
</code></p>
<p>In a nutshell, this styling indicates that all &lt;h2&gt; tags are also to be coloured red, rendered at 1.3 times the basic font size and to be bolded. To translate into relative English, whenever a browser sees and &lt;h2&gt; tag, it understands and renders the content as a large, red and bolded second-level heading. The style adds to the mark-up to make it richer.</p>
<h3>A One Sided Relationship</h3>
<p>It also helps to understand the relationship between mark-up language and styling language as being entirely one sided. Styles cannot function without mark-up, but the reverse is not exactly true. Let&#8217;s look at another literary example. Currently, I am reading the novel <i>The Awakened Mage</i> by Karen Miller. Allow me to quote the opening passage. </p>
<blockquote><p>
With one callused hand shading his eyes, Asher stood on the Tower&#8217;s sandstone steps and watched the touring carriage with its royal cargo and Master Magician Durm bowl down the driveway, sweep around the bend in the road and disappear from sight. Then he heaved a rib-creaking sigh, turned on his heel and marched back inside.
</p></blockquote>
<p>Now, let&#8217;s look at the same passage with all of the adjectives (or adjective-like phrases) removed.</p>
<blockquote><p>
With one hand shading his eyes, Asher stood on the Tower&#8217;s steps and watched the carriage with its cargo and Master Magician Durm bowl down the driveway, sweep around the bend in the road and disappear from sight. Then he heaved a sigh, turned on his heel and marched back inside.
</p></blockquote>
<p>It&#8217;s not much different, and still completely readable and understandable. It&#8217;s just missing some of the finer details that help contribute extra meaning to the passage. Now, let&#8217;s look at it with the nouns (and pronouns) removed.</p>
<blockquote><p>
With one callused shading his, stood on the and watched the touring with its royal and bowl down the, sweep around the in the and disappear from. Then heaved a rib-creaking, turned on his and marched back inside.
</p></blockquote>
<p>Without the nouns, the paragraph becomes completely non-nonsensical and looses all meaning, and the adjectives have absolutely nothing to work on. The same concept applies to HTML and CSS. While HTML can exist without CSS and still make sense, CSS without HTML is like throwing a bunch of adjectives onto a page without a single noun to give them context.</p>
<p>Which, of course, serves to emphasize the importance of the mark-up over the styling in design. Good, clean and well-structured HTML should always proceed the creation of equally good, clean and well-structured CSS.</p>
<h3>Scripting – Directive Language</h3>
<p>With that little aside out of the way, let&#8217;s get back to the matter at hand and look at the next type of language: scripting, which could also be called programming. This one probably has the largest series of specific languages that fall beneath it, including JavaScript, PHP, Perl, ActionScript and so forth. Each of these languages are unique in their own right, have varying syntax, functions, methods and core functionality. </p>
<div id="attachment_2719" class="wp-caption aligncenter" style="width: 510px"><img src="http://blog.echoenduring.com/wp-content/uploads/2010/03/javascript.jpg" alt="JavaScript is a popular form of scripting" title="JavaScript is a popular form of scripting" width="500" height="175" class="size-full wp-image-2719" /><p class="wp-caption-text">JavaScript is a popular form of scripting</p></div>
<p>However, like all programming languages, they share the common bond of being procedural, or as the title to this section suggests, directive. The purpose of any script is to provide a series of directions which, when followed, will yield a desired result. </p>
<p>This differs dramatically from mark-up and styling languages, which describe what something is and what it is like. Directive or procedural language is more like the instructions that came with your last IKEA purchase (though hopefully vastly more helpful). For example, here is the code for a simple JavaScript function.</p>
<p><code><br />
function doSomething(myValue){<br />
&nbsp;&nbsp;newValue = myValue+5;<br />
&nbsp;&nbsp;newValue *= 2<br />
&nbsp;&nbsp;newValue /= 3<br />
&nbsp;&nbsp;alert(newValue)<br />
}<br />
</code></p>
<p>If you don&#8217;t understand JavaScript, this function is basically a series of instructions, that go something like this:</p>
<ul>
<li>accept a value</li>
<li>add 5 to that value</li>
<li>multiply the resulting value by 2</li>
<li>divide the resulting value by 3</li>
<li>display the resulting value through an alert box</li>
</ul>
<p>That&#8217;s it – just a simple set of procedures acting upon a given value. And that&#8217;s really the basic premise of all the programming or scripting that I have ever done. It&#8217;s just a matter of writing a series of steps that explain to the computer how to accept, transform and return various bits of information. </p>
<p>Obviously, I&#8217;m simplifying a little bit, but probably not as much as some people might think. If you can write a basic set of directions about how to get from your house to your favorite pizza joint, you&#8217;ve already written a basic non-computer-based program. To move to programming on the computer – and specifically on the front or back-end of a website – is just a matter of learning how write appropriate commands in the right language! </p>
<h3>Query – Request Language</h3>
<p>Last of all, we have query languages, or what I am calling request languages. Chances are that many of you will never even need to work with this kind of thing, but I think that it&#8217;s at least important to know that exists. Basically, a query language, like SQL, is a way for a program or application to communicate with a database, appending, extracting or modifying information within specific tables. </p>
<div id="attachment_2721" class="wp-caption aligncenter" style="width: 510px"><img src="http://blog.echoenduring.com/wp-content/uploads/2010/03/phpmyadmin.jpg" alt="The popular phpMyAdmin system uses SQL to manage databases" title="The popular phpMyAdmin system uses SQL to manage databases" width="500" height="175" class="size-full wp-image-2721" /><p class="wp-caption-text">The popular phpMyAdmin system uses SQL to manage databases</p></div>
<p>I like to think of it kind of like a grocery list. Let&#8217;s suppose you want milk, bread, peanut butter and some eggs from the grocery store. You write this all down on a list, give the list to your significant other and send them off to the store. Your significant other (being so kind), enters the store, checks the list, retrieves the appropriate items and finally returns to you with everything you asked for. </p>
<p>That&#8217;s pretty much exactly what a query language does, except that instead of a store, it&#8217;s a database, and instead of groceries, it&#8217;s retrieving data. Here is an example of an SQL command for extracting data from a standard WordPress database</p>
<p><code><br />
SELECT `post_author` , `post_content`<br />
FROM `wp_posts`<br />
LIMIT 0 , 30<br />
</code></p>
<p>Basically, this list is saying that we want the information from the post_author and post_content fields in the wp_posts table. It also imposes a limit to only retrieve the information from the first 30 records. Just like a grocery list.</p>
<p>Admittedly, though, the grocery list metaphor is not perfect, since query languages like SQL can do so much more than just retrieve data. They can also add, remove, move and update data across multiple tables. Still, the basic concept is the same. The query has a single directive (select, add, drop etc), a listing of various bits of data and optional conditions to dictate and/or restrict what data is to be handled. </p>
<p>In one basic sense, a query can be similar to a script in that it dictates a command, and can actually contain some basic functions to manipulate the data. However, they key difference lies in the fact that a query only ever has a single command (though that command can be extremely complex), whereas a script or program generally contains multiple commands, which form the bulk of the procedure.</p>
<h3>Conclusion</h3>
<p>So there you have part 1 of this series. I hope to have accomplished something here for both coders and non-coders alike. For designers who don&#8217;t know how to code their own designers, I hope that this article has shed some light on the different types of coding languages that exist on the internet, and perhaps provided you a context through which to understand their various and different functionality within a website. </p>
<p>For coders, I hope to have provided a similar context, and allowed you to look at what you do from a different, language-based perspective. At the very least, I hope that I may have provided you with some helpful metaphors to help explain what you do to family in friends!</p>
<p>Of course, as I&#8217;ve already mentioned, this is only part 1 of a two part series. The second article will follow early next week, and will draw further parallels between scripting languages and the written language, including the roles of logic, syntax and grammar, and why they are all important. </p>
<p><strong>In the meantime, though, I&#8217;d love to hear your thoughts on this one. Which types of coding are you the most familiar and/or comfortable with? Is there another type of language that I missed (I hope not), or a different metaphor that you think better explains one of the four types outlined above?</strong></p>
<div id="crp_related"><div class="grid_12"><h2>Related Posts</h2></div><div class="grid_3 post"><h3><a href="http://blog.echoenduring.com/2010/03/09/more-thoughts-on-language-and-coding-for-the-web/" rel="bookmark" class="crp_title">More Thoughts on Language and Coding for the Web</a></h3><p class="posted">posted on <span>Mar 9, 2010</span>.</p><p class="crp_excerpt"> In this second article on the relationship between human languages and coding for the web, I will consider issues of linguistic evolution, language families, syntax and the way all of these things relate to coding for the web. I will also make a bold suggestion about your ability to code, even if you've never written a single line in your life! </p></div><div class="grid_3 post"><h3><a href="http://blog.echoenduring.com/2010/08/29/considering-an-xhtml5-methodology/" rel="bookmark" class="crp_title">Considering an (x)HTML5 Methodology</a></h3><p class="posted">posted on <span>Aug 29, 2010</span>.</p><p class="crp_excerpt"> In this article, I will be offering my own perspective on HTML5, my concerns about its openness in terms for formatting, and the benefits of XML syntax. All of this will bring us to the simple formulation of an (x)HTML5 methodology for readable, well written code as we move forward.  </p></div><div class="grid_3 post"><h3><a href="http://blog.echoenduring.com/2010/03/02/should-designers-know-how-to-code-thoughts-from-a-developer/" rel="bookmark" class="crp_title">Should Designers Know How to Code? Thoughts From a Developer</a></h3><p class="posted">posted on <span>Mar 2, 2010</span>.</p><p class="crp_excerpt"> Should designers be able to code? That's a big question that has been debated quite heatedly in recent weeks. In this post, guest author and developer Amber Weinberg weighs in with her own views on the subject, based on her own extensive experience coding her clients' designs.</p></div><div class="grid_3 post"><h3><a href="http://blog.echoenduring.com/2010/05/13/create-beautiful-css3-typography/" rel="bookmark" class="crp_title">Create Beautiful CSS3 Typography</a></h3><p class="posted">posted on <span>May 13, 2010</span>.</p><p class="crp_excerpt"> In this tutorial, we'll look at how to take basic markup and transform it into an attractive and beautiful typographical design through pure CSS3. There are no images or other external resources, just pure CSS magic. We'll also touch on some general typographical concepts along the way.</p></div></div><p><h3>Exclusive Content</h3>

<p>To thank you for subscribing to my feed, I am including exclusive, feed-only content for you at the bottom of each post!</p>

<p><strong>Current Freebie Code</strong> - 7ev165dd</p>


</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.echoenduring.com/2010/03/05/language-and-metaphor-an-alternate-view-on-coding-for-the-web/feed/</wfw:commentRss>
		<slash:comments>20</slash:comments>
		</item>
	</channel>
</rss>
