How is ASPX different than HTML? [Archive] - Glock Talk

PDA

View Full Version : How is ASPX different than HTML?


betyourlife
05-14-2009, 23:47
Looking at the tags of ASPX the language seems very similar to HTML. Can anyone compare and contrast the two? I have intermediate HTML skills, but have limited exposure to ASPX.

ron59
05-15-2009, 07:47
HTML is simply client side "markup". It tells the browser how to display the page.

ASPX pages are from the .NET programming methodology.
ASPX pages actually have two components, which are most often separated into two pages (but can be combined in one). For example, you'd see a page1.aspx, and then a page1.aspx.cs . The .ASPX page usually contains just HTML, but the ASPX.cs (or ASPX.vb) contains SERVER SIDE code. This is more intricate programming where "back end" work would be done, such as retrieving/storing information from a database would go.

ASPX pages allow using other concepts, such as master pages, where you develop the look and feel of the web site in one page, then all of your other pages inherit that same look and feel. Want to change the look and feel of the web site? Just change the master page and all other pages change too. You can get the same effect with HTML and CSS to some degree, but master pages can take it to another level.

jtm62
05-15-2009, 07:53
The simple answer is: .net is a microsoft proprietary scripting language, whereas, HTML is a free markup language. Because of this it is not governed by the World Wide Web Consortium standards. That is the main reason they are different.

Also, ASP is scripting language for server side functions like PHP and AJAX. All the page formatting is still done in HTML, that is why they look really similar. So really, your question should be, "How does .net differ from PHP?"

MavsX
05-15-2009, 19:10
jesus

ron59
05-16-2009, 10:52
The simple answer is: .net is a microsoft proprietary scripting language, whereas, HTML is a free markup language. Because of this it is not governed by the World Wide Web Consortium standards. That is the main reason they are different.



Ummm... NO. I'm about to fall out of my chair laughing at that last sentence.

While what you said is somewhat true... by no means is that the MAIN reason they are different. HTML lets you do NO server side code. If you're just developing a site that says "look at this", you don't need server side code. As I said before, HTML just specifies how the browser is to display a page, and that's it. You can't save information from a form, you can't retrieve information from a database, you can't have a login page and check the users login ID and password against a login table... NOTHING LIKE THAT.

Developing a REAL, WORKING web site, you MUST have some method of doing server side code. Classic ASP did this back in the day, and ASPX (.NET) is the current Microsoft way of doing this. And there are many other ways of doing it as well (PHP, etc).

This difference is the REAL *MAIN* difference, and is a very crucial one at that.

ron59
05-16-2009, 10:53
jesus


:rofl::rofl: Over your head? lol

jtm62
05-16-2009, 11:43
Ummm... NO. I'm about to fall out of my chair laughing at that last sentence.

While what you said is somewhat true... by no means is that the MAIN reason they are different. HTML lets you do NO server side code. If you're just developing a site that says "look at this", you don't need server side code. As I said before, HTML just specifies how the browser is to display a page, and that's it. You can't save information from a form, you can't retrieve information from a database, you can't have a login page and check the users login ID and password against a login table... NOTHING LIKE THAT.

Developing a REAL, WORKING web site, you MUST have some method of doing server side code. Classic ASP did this back in the day, and ASPX (.NET) is the current Microsoft way of doing this. And there are many other ways of doing it as well (PHP, etc).

This difference is the REAL *MAIN* difference, and is a very crucial one at that.

Yeah... maybe the word main was a bit of a stretch... but did you even read my second sentence? Also, ASP is scripting language for server side functions like PHP and AJAX. All the page formatting is still done in HTML, that is why they look really similar. So really, your question should be, "How does .net differ from PHP?"