Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Difference between ASP and HTML? 3

Status
Not open for further replies.

Maisie2007

Technical User
Apr 12, 2007
42
CA
What's the difference between ASP and HTML?

I have seen the asp pages, and I just dont see what the difference is. Why would you want to use asp over html?

What program does one use to create asp? Can you use a basic wysiwyg like frontpage?

........I know, these are dumb questions.......

Thanks,
Maisie
 
What's the difference between ASP and HTML?

Well... it's like the difference between a book and a television. With a book, whatever you do, each page will always be the same. Put the book down for a day, a week, a month, and when you come back, it'll still be the same. That's what HTML is like. With a t.v., you can look at the same 'box', and the picture changes, the sounds changes, the content is dynamic. That's the way ASP pages are.

I have seen the asp pages, and I just dont see what the difference is. Why would you want to use asp over html?

Suppose you wanted to make a website that displays cooking recipes. You could make a static (HTML) page for each recipe, or you could store the recipes in a database and then display each recipe on the same page (ASP). If you want to change the way the recipe is displayed, which would be easier? Change 1 page, or change each page?

What program does one use to create asp? Can you use a basic wysiwyg like frontpage?

There are many different programs you can use. Personally, I use visual studio.net. However, any ASCII text editor can be used. This turns out to be a matter of personal preference. In my experience with FrontPage, the ASP code it generates tends to be bloated (alot), so that resulting code it generates is many times larger than it needs to be.






-George

"the screen with the little boxes in the window." - Moron
 
Another explanation (in case you'd like it) - ASP is dynamic, meaning it can do a variety of things depending upon user interaction. HTML is much more limited, meaning that the user can do nothing more than what is shown on the screen to them. There is nothing underneath that helps to make it more functional or interactive. Essentially, the user cannot *do* anything with what they see.

Also, it may be worthwhile to point out that ASP can be used to create HTML while the reverse is not true.

As far as what application you can use to code ASP, you could use Notepad if you wanted. As George pointed out, any ASCII text editor will work just fine, it's up to you what you are more comfortable with. You will, of course, also need to have IIS installed on the machine you will be using. Hopefully these explanations will help to answer your questions. <kidding> Remember, there are no stupid questions, just stupid people. </kidding> ;-)

------------------------------------------------------------------------------------------------------------------------
"Men occasionally stumble over the truth, but most of them pick themselves up and hurry off as if nothing ever happened."
- Winston Churchill
 
Suppose today you make an HTML file. Suppose you put it on a web server. People browse to it and view it. Unless you edit the file, people will see the same thing tomorrow, next week, and next year.


The primary purpose of ASP is to make HTML. Suppose you make an ASP file and put it on the server. Now whenever someone browses to the file, the web server will execute the logic in the ASP and HTML will be produced. This newly produced HTML is then returned to the browser.

Obviously, if the page is supposed to look the same today, next week, and next year then it is a waste of time "re-make" the page with ASP each time some browser requests the page.

However some things change quite frequently. An example is your checking account balance. This may change several times per day. No bank would be able to offer online banking if actual people had to update an HTML file every time you account balance changed. Especially if you consider that the bank will have thousands of customers and each of them will have constantly changing account balances. Also you might not check your balance ever day, but someone would have to update the page just in case you did. Clearly this would be a huge waste of effort.

So for the bank, it is best for the web server to use a technology like ASP to create HTML only at the time you actually request the page.

 
Could you please point me to an asp page that's a real good example; so I have an example of what type of dynamic stuff html can't do?

Thanks,
Maisie
 
Actually this forum is itself an example of a dynamic web site.

When you submit a comment, the text is put into a database with along with indentifying fields like which "discussion thread" the comment belongs to, the ID of the user that submitted the comment, and the time and date.

Then, when you or anyone else views the discussion, the web server runs logic to read the database and construct HTML that contains all of the comments for this discussion. The comments are sorted by the order in which they were submitted. Also the user name of the person who submitted the comment is converted into a hyperlink that leads to a user profile page.
 
You could go to your bank's online account or credit card online account and will see examples of dynamic web pages. EBay or Amazon or sites where you can purchase things online are also examples.

------------------------------------------------------------------------------------------------------------------------
"Men occasionally stumble over the truth, but most of them pick themselves up and hurry off as if nothing ever happened."
- Winston Churchill
 
Without dynamic logic running on the web server, an actual person would be required to update each thread in each of the forums on this site... 24 hours a day.... 7 days a week!
 
Ohhh, ok - now I get it - thanks!

Is ASP really hard to learn, or is it as easy as html?
 
If you already know how to write a computer program then it is pretty easy to learn.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top