Ask YC: Learning Web Development, were should I start?
Here's my problem, I know, HTML, CSS, and I'm already learning JavaScript.
The thing is that I want to learn about server side programming, Python, Ruby, etc. But I also need to know DB like SQL.
So where do I start?
57 comments
[ 5.5 ms ] story [ 20.8 ms ] threadIt's practically requisite to understanding Rails or Django and is not so hard a project that you can't start to tackle it quickly (by reading any of the hundreds of simple web server tutorials online)
http://www.php-mysql-tutorial.com/
Here's another oldie, but goodie:
http://webmonkey.com/webmonkey/programming/php/tutorials/tut...
You didn't say which platform you're on, but you could save yourself a lot of trouble by installing an "all in one" LAMP distro, even on Windows.
You could just say, "Screw it all," pick up a PHP book and dive in head first. You'll pick up some pretty bad habits along the way, but it depends on how you like to learn.
Here's a syllabus that I'd suggest to really get your head around web programming and understand what's going on:
HTTP--learn the basics of what the protocol does, and why. Learn the different response pages, because they are going to be your error messages.
Web servers--you just need a 100 ft overview. Learn how to setup and configure a web server.
Programming--You need to pick a language, Python or Ruby and learn how to at least do some basic programming with it. I'd recommend Python, personally. It's more explicit, and has less "magic". You probably need to understand variables, iteration or looping. You need to understand some basics of the object oriented programming concepts like methods, classes and scoping. And, if you're going to get into any of the web frameworks, you need to understand what things like a dictionary and array are. At least a basic understanding of regular expressions are necessary to learn Django's URL naming convention. The better you know programming itself, the better web developer you'll be, and more things will become possible for you to program.
CGI -- This is the ancestor to pretty much all dynamic web pages, and the foundation of most web development. Pick the language that you're learning, and go through some tutorials on CGI scripting for the language you're going to focus on. And, this will help you understand the basics of what goes on in the address bar, GET and POST methods of the HTTP protocol. You'll also get familiar with the idea of taking variables and inserting them into HTML templates dynamically, which is the basis of most web frameworks.
Learn SQL, and database basics. You need to understand what a database is, how to create a database, why databases are important, how to create and drop tables, how to do queries, etc... Having at least a basic understanding of relationships, foreign keys and constraints is helpful when reading some of the web framework documentation. You really should understand how to do a query in SQL, just so you can understand what the web framework is doing for you.
Finally, pick up a web framework, and start to work through it. After learning the above, learning the web framework will tend to make a lot more sense than if you dive into a web framework deep end first. Pick the framework that's most popular for your language, that way, you can be assured you will have plenty of documentation to work with. I'd recommend Django for Python, and Rails for Ruby.
Lather, rinse, repeat. Iterate through the above steps, and learn more and more each time you approach each subject.
Can you please point me some of the information sources you used.
Thanks again.
If you're interested in how it all works, dig into WSGI. And if you find that web.py is too low level, transition to Django after you have a feel for how web apps work.
While webpy is small, I found myself often looking at the code, which has little commenting, to understand what's going on, or how to use a certain feature, mainly b/c the documentation is so lacking.
CherryPy might be a better choice.
Python is a little more "corporate", with a little more regimented style (e.g. significant whitespace, PEP style guide - http://www.python.org/dev/peps/pep-0008/). CherryPy is super-simple to get started.
Ruby is a little more "hacker", with a more idiosyncratic cast of characters such as DHH and _Why and a little more focus on coolness and tricks. Rails is the way to go, but you can get up and running with the basics with the Camping Framework in about 10 minutes.
Online tutorials are good for a quick, down and dirty overview of a topic. But, if you're going to learn something a bit more in depth, I'd think that you're better off looking at a book. It's pricey, but it's worth it for me. I figure I'd spend $40 a month on tech books anyway. I'd might as well pay them and get the whole library as well as the Lynda.com video all at the same time.
Also, if you're really serious about it, I might consider finding a web database development class or certificate program somewhere. It might be slower going than you want, but you'll have a more complete understanding of the subjects once you were done.
Good Luck!
(PS: In the Bay area, foothill college is great, IMHO, for continued education)
http://tryruby.hobix.com/
And from there you can start playing with Rails, which is a joy to use. I recommend starting with "Agile Web Development with Rails". I've only read excerpts from "The Rails Way" but it seems good, too.
Bottom line for me -- programming Ruby and building Rails apps is fun.
Why not then just use Django or Turbo Gears or Ramaze or Nitro then?
In the end, you have to live with the underlying language.
My personal experience is with Perl and Java, both of which are going the way of the dodo, or so it seems. So, I can't recommend any of them in good conscience.
But, whatever language you learn, I would first take some time to write some basic non-web programs. Once you are familiar with the basics of the language (variables, flow control, arrays, hash tables, etc.) then I would write some CGI-based web forms. That would give you an idea of how the basic functionality of a web site is chiseled from the primordial silicon.
Then, when you pick a framework you will know what is being abstracted and what parts of the web programming tasks are being streamlined.
Sure rails hides a lot but it'll introduce you to some best practices, like the concept of MVC etc.
Lynda tutorials are great. I'd also recommend free ones:
http://railscasts.com/
http://www.akitaonrails.com/2008/2/1/rolling-with-rails-2-0-...
And for-pay ones at http://www.peepcode.com
Also, grab "The Rails Way" book by Obie Fernandez (it's THE BEST book on Rails.. when you learn the basics, it's better than 'Agile Web Development with Rails') and "The Ruby Way" by Hal Fulton.
I've heard good things about "The Rails Way" but haven't yet had a chance to look at it.
I also suggest The Ruby Way (though perhaps I'm biased); however, the Web dev section is dated. :(
First, let's start with the languages they are based on, since performance and scalability depends on this. Do you feel Ruby is more mature than Python too?
I mean, no one is keeping you from working using Django .96, but several of the neater features in the platform (ContentTypes & Generic relations) are a little sketchy at the moment.
I really don't have anything against Ruby and Rails. I really like the Rails framework and there's a lot of great stuff there. I just don't think that Ruby is a best first language to learn.
Or---judging from the URL---just go for the technology these guys used, rather than the one they want to teach you.
Ruby: Ruby on Rail, Merb PHP: CakePHP Python: Django
I truly think that understanding the language itself will help a lot before jumping into the framework.
I already knew a good amount of Python though.
djangoproject.com
1. How to program (hack) 2. How to hack on the web 3. How to create application databases for your web stuff
I suggest tackling each of these separately in turn if possible, starting with #1. Python and Ruby both make great beginner's languages.
Be goal-oriented. Once you know your way around a little, worry less about having the right technology and more about getting things done. Create something that you can use every day, like a blog, a calendar program, or something like that. Ignore all the "X is better than Y" talk on the Internet and just work hard on getting stuff done: that's all that really matters.
The best advice I can give is to remember that you're at the start of a long road. You need treat it as such. No matter how smart you are (or think you are), it will take you long time to learn everything you need. Persevere.
Err on the side of learning more than you need. You'll find later that knowledge will be useful. Be curious.
Now, start creating. Learn the necessary technologies as you go along, mixing in healthy doses of theory and best practices when you get the feeling there's a better way to do what you're trying.
It's hard to learn technologies in isolation, when they have no meaningful connection to problems you're solving. So give yourself an interesting challenge that can be overcome with the tools you want to learn.
If you're using automated tools along the way (installers, package managers, code scaffolding), consider doing what the tools do for you manually. Unravel things and get closer to the metal until you're satisfied.
Consider sharing the source code of your project with others. Maybe nobody will take notice, but it will give you motivation to make your code beautiful.
As far as specifics, Python strikes a nice balance among power, maturity, and marketability. MySQL is standard. Be sure to "unravel" your DB code into SQL without just relying on framework magic.
Anyone recommending a framework before someone understands web programming isn't someone I would hire. Frameworks are where you go when you finally get what is missing with your web programming language. It might take you years to get to that point.
Go with PHP. Period. People are going to blah, blah, blah about how PHP gives you bad habits, has bad function naming, ran off with their kid sister, whatever. PHP is a mess but it works. Name a webpage .php and you are good to get going. Try that with Ruby.
PHP is a tool that gets the job done and let's you quickly become immersed in web programming. If you don't know your GET from your POST, a great Ruby framework ain't gonna help you.
Once you get PHP figured out (and now are employable as a programmer?), try Python or Ruby out. They are gorgeous, elegant languages. I love using both of them. Then slap a great framework like Django or Merb on top. You'll love it.
But only after you get the basics down. I'm ashamed at you guys, really.
-1 for attitude.
We're even.
... if you can avoid PHP. It will do all those things mentioned above, and more and more Python and Ruby are becoming common.
Go to your local craigslist web/info design job page and run a search for PHP and count how many ads come up. Then run searches for Python and Ruby. That's enough help for me when it comes to making a decision.
1-2 page exec summaries of popular languages and the specific problems they solve. Include links to resources that explain things further. It would help to get a snapshot from 1000 ft. above the situation.
There is definitely a need here.
Thanks
http://www.instantdjango.com
It includes a portable Django development environment for Windows, no installation required, and it even runs from a USB thumb drive. The tutorial walks you through creating a simple website, and explains what is happening each step of the way.
The website is overdue for some updates, and I really need to finish writing the second chapter, but you might find it an interesting way to spend 45 minutes.
For me programming is all about Logic.
good-luck