----------------------------
Summary
----------------------------
If you want to learn how to program, I suggest picking a language with a shorter learning curve. I actually suggest against writing an web page right out the gate due to the sheer number of things that you will have to learn all at once.
The trick to learning this stuff is to have patience, learn one thing at a time, and have fun!
----------------------------
Learning a programming language
----------------------------
As I mentioned before, there are so many aspects to learn about programming for the web that I don't suggest starting there if you simply want to learn how to program first.
It does not really matter what programming language that you start with but pick one and learn it. Once you know one language, it will be easier to learn another; Keep in mind that programming languages are all similar but have different strengths and weaknesses.
I suggest grabbing this free book which teaches you how to think, in general, as a programmer without emphasizing the language too much.
"Think Python: How to Think Like a Computer Scientist" (pdf)
http://www.greenteapress.com/thinkpython/thinkpython.html
You will then need to download the python program to your computer. This program is called a "run time" or "interpreter". This program will "understand" the commands you send it. It "interprets" them so that the computer knows what you mean.
Tip: use python 2.6 and not python 3.0
Python for Windows:
http://www.python.org/ftp/python/2.6.1/python-2.6.1.msi
Python for OS X:
Python comes with OS X on the Mac. Simply open the "Terminal" and type 'python' at the command prompt.
----------------------------
Technologies for the web
----------------------------
Note: you will notice a lot of terms mentioned below. The sheer number of them to learn is why I do not suggest starting with "web programming" in general since "web programming" means you will have to learn many things all at once.
HTML
This is not a programming language as many people think. It is a "markup" language which is to say that it helps you lay out how you would like a web page to LOOK (markup/design to make a button "look pretty and be on the bottom of the page") but not how a web site should ACT (programming the button to "do such-and-such when it is clicked")
CSS
Once you are familiar with HTML, CSS can take a lot of redundancy out of the HTML to help you change the look of your web site more easily.
Server Side Programming Language
One you know how to get a web page to look like you want it to, you will need to make it ACT like you want it to by adding interactivity. For example, making a button "do" something vs "looking" a certain way (HTML/CSS) This is where a programming language comes in.
Client Side Programming Language (Javascript)
If you're going to do web programming, you'll probably also need to learn Javascript.