DT211/3 Internet Application Development Active Server Pages & IIS Web server.
Published byModified over 4 years ago
Presentation on theme: "DT211/3 Internet Application Development Active Server Pages & IIS Web server."— Presentation transcript:
DT211/3 Internet Application Development Active Server Pages & IIS Web server
Introduction Purpose: to provide some practical experience of using IIS web server and basic ASP pages Active Server Pages Developed by Microsoft Active Server Pages is a ‘programming model’ (as is CGI) – Similar to JSP, script is interspersed with HTML Pages must have a file extension of.asp – otherwise, server won’t know to process as an ASP page
Web Servers Microsoft has two web servers that are usually used to run ASP IIS (Internet Information Server – Windows NT/XP Pro/2000 PWS (Personal Web server) – up to Windows 98 IIS is free with Windows 2000/XP Pro, part of the Windows NT 4 option pack. PWS is a scaled down version of IIS for Personal Computers. ASP pages can be run on other servers, provided the server has the ASP engine. Sun Microsystems have produced a product called Chili!Soft ASP which enables ASP to be used on other web servers including, Apache, I-Planet, Zeus, Red Hat Secure Server, etc, using various operating systems including, Linux, Solaris, HP-UX, AIX, etc.
Set up a web site in IIS Open administrator tools in Control panel – and open the Internet Server Manager Shows directory structure for IIS Default web site is the HTTP site. Expand the default web site (shown overleaf) and create a virtual directory in the Webpub directory - this will hold the documents for your web site. (A virtual directory is just an alias for a real directory that exists). This virtual directory will become part of the web address to access any documents contained in it e.g. http://localhost/Webpub/examples/blahblah.html
Set up a web site in IIS Access permission = security level choices for the virtual directory Read = users can read and download files in the directory Run Scripts = allows scripts in the directory to be run Execute = allows applications in the directory (e.g. CGI ) to be run Write = allows a Web page to accept user input (e.g. credit card input Browse = allows users to navigate from one web doc to another via hyperlinks http://www.webwizguide.com/asp/tutorials/installing_iis_w inXP_pro.asp
Loading a document from IIS To load a HTML doc using IIS: First, ensure HTML doc has been placed in the virtual directory Then type the web address for your html doc into the browser. This will be: e.g http://localhost/webpub/alias/index.html To load ASP documents – do exactly as above, and remember to access using “.asp” e.g http://localhost/webpub/alias/somepage. asp What ever you called the directory
Uses of ASP Can be used similar to JSP for: Dynamically edit, change or add any content of a Web page Respond to user queries or data submitted from HTML forms Access any data or databases and return the results to a browser Customize a Web page to make it more useful for individual users Provides security since your ASP code can not be viewed from the browser Since ASP files are returned as plain HTML, they can be viewed in any browser
Differences between VBScript and Visual Basic VBScript explicitly supports one data type only, the Variant VBScript is an interpreted language VBSCript cannot directly use the Windows API There are few syntactical different in the use of some internal functions
How to start your IIS account The accounts are on the student webserver and can be access to through FrontPages \\erin.student.comp.dit.ie\dt211-3 Using and window password Your web site in IIS can be published to through Front- page by opening Http://www.student.comp.dit.ie/dt211-3