Get Me Started in HTML!

A newbie with HTML, I desire to build a website. I have programming experience in earlier languages of the day, like Clipper, from which grew “C” language (i.e., C+, C++). So, I have a good background. Upon reading some basics, I wanted to experiment offline (i.e., not hosted/not live). The book made it seem so simple. So, I wrote a short html program in Notepad++ v.6.9, , per the book’s example. When I selected “Run in Firefox” (from a pull-down menu in this editing software), I expected a Firefox browser to open and my formatted text would appear. Instead, Notepad opened a viewing window, shall we say, showing exactly what I had entered, tags and all. And yes, I made sure all opening tags were completed with closing tags…so what gives? Furthermore, this book’s example included an anchor to a website’s name chosen by the author. In reality, it seems to me the author is misleading the reader - the website must be valid AND hosted, true?

Bottom line? How do I get started offline and view real-looking results? These “real-looking” results are critical to knowing what I’ve done right, wrong, and where to tweak. Thanks!

You should drag and drop it into Firefox directly. If it doesn’t display correctly after that, you may be missing the beginning and end tags that are **

 

** only in the proper < . > format.

It’s possible your file extension is wrong. Firefox will only render a local file as html if the extension is .html or .htm (possibly a few more). So, for example, if your file is called webpage.txt or webpage.html.txt, it will show the raw file instead.

Firefox will show the file extension in the address bar when you open the file, it will look something like file:///C:/xxx/yyy/zzz***.txt***

[nitpick]Clipper was developed as a language for dBASE in 1985. C was developed at Bell Labs between 1969 and 1973.[/nitpick]

In addition to what the others said you can also browse to where you’ve saved your “helloworld.html” file, double click it and it should open in your default browser.

Nothing of what you know about real programming languages will transfer to HTML IMHO. It’s simply a markup language and has no programming language features such as if/then/else or looping. However, I’ve not looked at HTML5 so the previous could be complete bollocks.

I have a web site and a sandbox on my home computer where I test all changes. The address of the sandbox appears on my firefox browser as: file:///C:/math/pdffiles/index.html. The stuff after file:/// is where that index file actually is. But the way I found this address line was by double clicking on that index.html and it loaded automatically into the browser. YMMV.

I use Notepad++ to run HTML files locally every day. I do it just like you did - Run in Firefox. I am guessing Tom P. is right with his assessment. You did not make a .html file.

I display web pages directly from a local file as described above sometimes ( file:///user/home/~/html/index.html for example). But there’s another way too: Run a web server on your machine and have a real web site. Plunk the file there, and then surf to http://localhost/index.html (e.g.).

This, of course, requires installing and configuring a web server like Apache and setting up configuration files and such. But you can find step-by-step how-to instructions on-line, and it’s an educational exercise doing so.

(ETA: Note, for example, that this message board software turned my “localhost” reference, above, into an actual link. On my machine, I can actually click on that and it will open my own local web page that I host on my own machine.)

Download Microsoft Expressions and install.
(Unless you are a rabid anti M/S person!)
It is a powerful W.Y.S.I.W.Y.G. editor which supports many modern web tools.

It also allows you to split the page, of to view “code only” so you can experiment and view the code. Or download other pages to see how things are done.
If you are anti M/S there is a free program called bluegriffon that is similar.

Have you tried something like http://www.w3schools.com/html/tryit.asp?filename=tryhtml_links_w3schools ?

Writing HTML from scratch in a Notepad-ish text editor is about the same idea as writing a simple CS101 bubble sort in assembler. So last century, not even last decade.

Kinda fun to do once just to prove a point, but not a way to become productive with the technology for either professional or personal reasons.

If you want to see something both silly & horrifying, go to www.google.com while not logged in & [view source] on that familiar & seemingly simple search page. It’s a struggle to even *find *the HTML in there. And what HTML there is represents only a tiny fraction of the content of the page.

That’s a lot closer to how a modern website looks under the hood than is



<!doctype html ...><html>
<head>Jinx be awesome!1!!</head>
<body>Hello world!</body>
</html>

I’m sure there’s much truth here … but also much exaggeration.

Just as one example, consider a page from one fairly respected site. I’ve no idea whether Ms. Manco or others use a “Notepad-ish text editor” (I use vi due to decades-old habit) but you’ll see that most of the text at this content-rich site is … content! I think tags etc. and css files were laid out by hand. There’s a little bit of Javascript, mainly to support the elegant format change (see upper-left corner of the webpage).

Good ideas for css and javascript can be pulled off the web, but I’ll guess the packaged Writing_Html_for_Dummies methods tend to hinder rather than help that.

Ms. Manco’s pages have some fancy features, yet are built with personally hand-crafted Html. It’s easy to build a simple content page without fancy features. Or to copy a nice page with nice features and replace its content with your own by hand.

For sites that are static “magazines” or “pamphlets” such as that I agree with you. And that I was exaggerating for that use case. And you’re right, your cite’s HTML is very clean and probably hand-done.

For something like an page at Amazon, Home Depot, CNN , or NFL not so much. Nor at Wordpress or any other blog engine.

The key difference is a pamphlet page is intended to be essentially static and immortal. An NFL or Home depot page is ephemeral and part of a coherent web application designed for user interaction, not just user reading.

To be sure our OP wants to crawl, then walk before running. But it’s worth getting the idea from the very beginning that most of the web-world is *not *dumb HTTP file servers serving static web pages consisting of raw HTML.

I’ve also seen the opposite extreme where the HTML <body> contains a single empty named <div> and 100% of what goes in that div is generated by AJAX-style interaction between browser-side JavaScript and server-side REST services. All of which is styled purely by CSS.

Most production sites today are somewhere in the middle.

I know of an older man who provides tutorials for people wanting to learn to use HTML. Here are two links to his sites:

http://www.wise-old-man.com/quickhtmltutorial/
http://www.wise-old-man.com

I Googled “wise old man html” to get the links to these two sites.

They are titled “Wise Old Man Help Pages” and “Wise Old Man HTML”.

I don’t know what to say about his calling himself “Wise Old Man”. But I will tell you his sites are targeted towards people who have not had much experience with programming or any web design.

Take a look and see what you think. You may like them. Or you may not.

Either way, Good luck!

I work for The Internet and I make those fancy sites that are ephemeral and dynamic and all that jazz and while the most technically impressive parts of my day consist of SQL and C#, I probably wouldn’t have a job if I didn’t know HTML (well). I was brought in because the people who know how to make the pretty pictures and the people who know how to churn out data don’t know how to lay it out on a page.

I write and edit lots and lots of HTML in the course of my job, whether it is building the static code around the dynamic data, or adding dynamic HTML data to an existing HTML template - which is inevitable for even the most elaborate of templates and CMS systems.

Also important these days are HTML email newsletters, which are just big stand-alone HTML files. Great skill for anyone to have.

The existence and popularity of dynamic Web content in no way negates the need for actual HTML code to deliver it to the end user.

Written for kids

http://www.lissaexplains.com/