'''Active Server Pages''' ('''ASP''') is [[Microsoft]]'s [[server-side]] [[Active Scripting|script engine]] for dynamically-generated web pages. It is marketed as an add-on to [[Internet Information Services]] (IIS).
Programming ASP [[website]]s is made easier by various [[Wiktionary:built-in|built-in]] [[Object (computer science)|objects]]. Each object corresponds to a group of frequently-used functionality useful for creating [[dynamic web page]]s. In ASP 2.0 there are six such built-in objects: Application, ASPError, Request, Response, Server, and Session. Session, for example, is a [[http cookie|cookie]]-based [[Session (computer science)|session]] object that maintains [[variable]]s from page to page.
Most ASP pages are written in [[VBScript]], but any other [[Active Scripting]] engine can be selected instead by using the <tt>@Language</tt> directive or the <code><script language="language" runat="server"></code> syntax. [[JScript]] (Microsoft's implementation of [[ECMAScript]]) is the other language that is usually available. [[PerlScript]] (a derivative of [[Perl]]) and others are available as third-party installable Active Scripting engines.
InstantASP and ChiliASP are technologies that run ASP without the Windows Operating System. There are large open source communities on the [[world wide web|WWW]], such as [http://www.aspnuke.com/ ASPNuke], which produce ASP scripts, components and applications to be used for free under certain license terms.
==Versions==
ASP has gone through six major releases:
* ASP version 1.0 (distributed with IIS 3.0) in December 1996,
* ASP version 2.0 (distributed with IIS 4.0) in September 1997,
* ASP version 3.0 (distributed with IIS 5.0) in November 2000,
* [[ASP.NET]] version 1.0 (part of the [[.NET Framework|Microsoft .NET platform]]) in January 2002 <br />(the pre-.NET versions are currently referred to as "classic" ASP)
* [[ASP.NET]] version 1.1 in April 2003
* [[ASP.NET]] version 2.0 (released on [[November 7]], [[2005]]).
ASP.NET was originally called "ASP+" or "ASP PLUS" before the .NET name was introduced.
The move from ASP 2.0 to ASP 3.0 was a relatively modest one. Some of the most important additions were the [http://msdn.microsoft.com/library/default.asp?url=/library/en-us/iissdk/html/d47bdda3-96e1-46c3-b872-a038c2a61317.asp Server.Transfer] and the [http://msdn.microsoft.com/library/default.asp?url=/library/en-us/iissdk/html/db562da1-d49d-4fe5-9747-64ef530de23f.asp Server.Execute] methods, as well as the [http://msdn.microsoft.com/library/default.asp?url=/library/en-us/iissdk/html/541697df-5fb9-40a4-8fa1-380b4717cbf1.asp ASPError object].<ref>4 Guys From Rolla's [http://www.4guysfromrolla.com/webtech/010700-1.shtml A Look at ASP 3.0]</ref> Microsoft's [http://www.microsoft.com/technet/prodtechnol/windows2000serv/reskit/iisbook/c01_programmability.mspx?mfr=true What's New in IIS 5.0] lists some additional changes.
The move from ASP 3.0 to ASP.NET was a significant change. ASP.NET introduced the ability to replace in-HTML scripting with full-fledged support for [[.NET Framework|.NET]] languages such as [[Visual Basic .NET]] and [[C Sharp programming language|C#]]. In-page scripting can still be used (and is fully supported), but now pages can use VB.NET and C# classes to generate pages instead of code in HTML pages.
There are solutions to run "Classic ASP" sites as standalone applications, such as ASPexplore, a software package that runs Microsoft Active Server Pages offline.
==Sample usage==
Several scripting languages may be used in ASP. However, the default scripting language (in classic ASP) is [[VBScript]]:
<source lang="html4strict" line>
<html>
<body>
</source>
<source lang="asp" line start="3">
<% Response.Write "Hello World!" %>
</source>
<source lang="html4strict" line start="4">
</body>
</html>
</source>
Or
<source lang="html4strict" line>
<html>
<body>
</source>
<source lang="asp" line start="3">
<%= "Hello World!" %>
</source>
<source lang="html4strict" line start="4">
</body>
</html>
</source>
The examples above write "Hello World!" into the body of an HTML document.
Here's how to connect to an MS Access Database
<source lang="ASP" line>
<%
Set oConn = Server.CreateObject("ADODB.Connection")
oConn.Open "DRIVER={Microsoft Access Driver (*.mdb)}; DBQ=" & Server.MapPath("DB.mdb")
Set rsUsers = Server.CreateObject("ADODB.Recordset")
rsUsers.Open "SELECT * FROM Users", oConn
%>
</source>
[[http://allaboutaspdotnet.page.tl/]]==Apache::ASP==
[http://www.apache-asp.org/ Apache::ASP] provides an Active Server Pages port to the [[Apache Web Server]] with Perl scripting only, and enables developing of dynamic web applications with session management and embedded Perl code.
==See also==
*[[WISA]]
*[[JavaServer Pages|JSP]]
==External links==
* [http://en.wikibooks.org/wiki/Active_Server_Pages Active Server Pages Wikibook]
* [http://www.asp101.com ASP101 - Active Server Pages Code & Tutorial Site]
* [http://www.w3schools.com/ ASP samples] Tutorials on ASP and ASP.net programming.
* [http://www.webdevbros.net/ajaxed/ ajaxed] ASP Ajax Library
* [http://www.maxiasp.com MaxiASP : Turkish ASP Articles]
* [http://forum.maxiasp.com MaxiASP Forum : Turkish ASP Answer-Question Database]
* [http://msdn2.microsoft.com/en-us/library/0ad0dkea.aspx Microsoft's VBScript Fundamentals] Describes the VBScript language
* [http://asp3wiki.wrox.com Beginning Active Server Pages 3.0] Online Book - Free Access to Entire Book
* [http://www.powerasp.com PowerASP - One of the 1st ASP Code & Tutorial Sites]
==References==
{{reflist}}
[[Category:Microsoft server technology]]
[[ar:صفحات خادم نشطة]]
[[bs:ASP]]
[[ca:Active Server Pages]]
[[cs:Active Server Pages]]
[[da:Active Server Pages]]
[[de:Active Server Pages]]
[[es:Active Server Pages]]
[[eo:Aktivaj Servilaj Paĝoj]]
[[eu:Active Server Pages]]
[[fr:Active Server Pages]]
[[id:Active Server Pages]]
[[is:ASP]]
[[it:Active Server Pages]]
[[he:Active Server Pages]]
[[lv:ASP]]
[[hu:Active Server Pages]]
[[ms:Active Server Pages]]
[[nl:Active Server Pages]]
[[ja:Active Server Pages]]
[[no:Active Server Pages]]
[[uz:ASP]]
[[pl:Active Server Pages]]
[[pt:ASP]]
[[ru:Active Server Pages]]
[[sk:Active Server Pages]]
[[sr:ASP]]
[[fi:ASP]]
[[sv:Active Server Pages]]
[[th:เอเอสพี]]
[[vi:ASP]]
[[tr:ASP]]
[[uk:Active Server Pages]]
[[zh:Active Server Pages]]