dacs.doc electric

 

Intro to Web Programming

By Mike Kaltschnee

 

IF YOU'VE SPENT any time on the Internet, you've probably noticed the fancy forms you can fill out and the ability at certain sites to search an online database. You've probably also wondered just how these things were done. This month I'll take you on a tour behind the scenes and share some of the secrets with you.

The way an online form works is really simple: You fill out a form, maybe buying something online or requesting information, and hit the Submit key. This triggers the execution of a program that then runs on the Web server. The program takes the information you filled out and then does something with it, maybe adding it to a database or sending e-mail. Finally, a response is sent back to your Web browser, typically an acknowledgement that your request was processed.

www.webspice.comI'll give you an example of how we added the registration form to our site, www.webspice.com. When people enter our site, we offer them the chance to receive 175 free images in exchange for their e-mail address. Originally we wrote a program that would take their information and e-mail it to us, but when we signed up with GTE for our Web hosting, the company provided us with several pre-written programs, including a form-to-mail program.

All we had to do was add a simple bit of HTML code to our page, and we were done. You can go to our site and try it yourself, but when you do, be sure to check out exactly how we did it. You can view our work by selecting "View" and "Source" from the menu bar in your browser when you're on the page with the form.

It's really simple to add this type of functionality to your site without programming. Kristi Stone, a former DACS member, has a company that adds e-mail forms, guestbooks, and more to your site at a low monthly cost (a Web programmer can be very expensive). Visit her site at www.i-depth.com for more information.

If you're the type of person that wants to do it yourself, you need to pick a programming language. Although you can use virtually any language (No, not French, wise guy. You need a computer language.), the majority of Web programs are written in Perl, Java, JavaScript, C++, or ASP. It helps to have some experience in computer programming, but it can be as simple as the Basic language.

Perl, one of the first programming languages used on the Web, is very similar to "C" and even has some similarities with the Basic language. Java, relatively new, is designed to make it easy to write programs that will work on almost any type of computer, even Macintosh or Sun machines. JavaScript is a language that runs on your computer and is great for making things happen in a Web browser. ASP, or Active Server Pages, is even newer. Microsoft designed it to look like Visual Basic, but it is a great way to write programs on the Internet. If you have a language you like to program in, such as Visual Basic, you can use it on the Internet.

You can learn how to do this yourself at home without buying any new hardware or software. Microsoft has graciously provided a free program, Personal Web Server, which runs on Windows 95, 98, or NT. If you have Windows 98, NT 4, or even FrontPage 98, you already have it. If you don't, you can download it from www.microsoft.com. Once installed, you can do almost everything that the $800 Windows NT Server with Internet Information Server (IIS) can do, albeit slower. It can run Perl, ASP, and even Java.

If you want to learn more about Web programming, take a course at your local college, get a book, or even go online. But try these sites first:

www.developer.com - This is really a collection of great Web sites for learning programming. It has sample code, articles, and even free online books to teach you how to program on the Web.

www.webmonkey.com - What a strange name this is for a great site and a great place to start. You'll find lots of tutorials on Web programming here.

www.zdu.com -- Ziff-Davis University is an online school offering dozens of Web-related classes for a low monthly cost.

www.Microsoft.com -- The same people who brought you Microsoft Word bring you tools, sample code, articles, Web servers, and much more.

www.activestates.com -- You can get Perl for Windows 95, 98, or NT for free here.

That's it for this month. Tune in next month for more information on file compression and other topics.


Mike Kaltschnee is a founder of DeMorgan Industries Corp., the leading developer of Web graphics. You can reach Mike online at mikek@demorgan.com.

BackHomeNext