300 likes | 426 Views
Web Pages. Static Web Pages. Htm and Html pages are static. SHTML. Pages tagged with "shtml" reveal that "Server Side Includes" are being used on the server With SSI a page can contain tags that indicate that another file should be inserted in place of the tag in the existing page
E N D
Static Web Pages • Htm and Html pages are static
SHTML • Pages tagged with "shtml" reveal that "Server Side Includes" are being used on the server • With SSI a page can contain tags that indicate that another file should be inserted in place of the tag in the existing page <!--#include virtual="/USIS/templates/ssi1.html"-->
SHTML Server side include
SHTML • So a page is lifted off the server's disk and the server makes all the substitutions indicated by SSI • Then it sends the final page to the client • This approach makes it very easy to change things like headers and footers on pages across an entire site
Dynamic Web Pages • Pages that contain content which changes automatically i.e. without the web page creator editing it manually
ASP • Active Server Pages (ASP) is a Microsoft technology that enables dynamic web pages using ActiveX scripting -- usually VB Script • A web page can contain Visual Basic code that the server executes when it lifts a page off the disk • This code can do just about anything: • read databases • run other programs • custom format pages based on the user's ID, etc.
PHP • PHP Hypertext Preprocessor is a server side embedded scripting language (like ASP) used to create dynamic web pages • PHP has similar functionality to ASP but is Open Source and cross-platform
Cold Fusion • Created by Allaire Corporation who merged with Macromedia in 2001 • Includes a server and a development toolset designed to integrate databases and Web pages • Cold Fusion Web pages include tags written in Cold Fusion Markup Language (CFML) that simplify integration with databases and avoid the use of more complex languages like C++
JSP • JSP Java Server Page • Extension to the Java servlet technology that was developed by Sun • Like ASP, JSPs have dynamic scripting capability that works in tandem with HTML code, separating the page logic from the static elements to help make the HTML more functional (i.e. dynamic database queries) • Like PHP, JSPs are not restricted to any specific platform or server
NSF • The .nsf extension is used on sites powered by Lotus's Domino server • This server takes standard Lotus Notes databases and dynamically converts the content of those databases into web pages when the page is requested • The site's pages can change throughout the day depending on the content of the databases
Server Side Scripting • ASP, JSP, Cold Fusion, PHP, etc. are all server side scripts • These scripts reside either in the HTML document or in another document pointed to from the HTML document • The web server interprets the scripts when the web page is requested
Server Side Applications • Common Gateway Interface (CGI) defines a standard interface between a Web server and an independent application • CGI is very general because the application is completely decoupled from the Web server • Thus the application must be launched independently for each request • There is no convenient place to store state information between web requests
CGI • CGI scripts can be written using many different languages e.g. • Perl - Interpreted high-level programming language with good process, file and text manipulation facilities • Java • C++ • C
CGI Problems • All server run programs such as CGI must overcome the following problems: • Starting and stopping the application • Passing data from the client to the application • Passing data from the application to the client • Status and error reporting • Passing configuration information to the application • Passing client and environment information to the application
Server Side vs. Client Side • All of the dynamic web page technologies that we have seen so far have been server based • The server runs the script or application and does all the work • The code is not generally visible to the client • The client gets sent formatted HTML (such as database search results, images etc)
Client Side Scripting • Client-side Scripts are programs that run inside an Internet browser on the client machine • Small programs in the source form of an interpreted language are embedded directly into the Web page • When the browser loads the page, the browser has a built-in interpreter that reads the script code it finds in the page and runs it
Client Side Scripting • Three main client-scripting languages: • JavaScript • VBScript • JScript • Powerful for rapid development of simple applications • Lack of compile- time checks makes them difficult to use for larger applications
Plug-ins • An add-on software application that permits software developers to add new capabilities to the browser using a defined programming interface • Provides the ability to display a new type of data using the browser itself rather than starting a separate application
Flash • Flash is a 2D vector graphics application, enabling web based interactive animation • Flash is now the standard format for rich animation on the Web Flash Example
Java • Object oriented programming language • Includes specification for virtual machine which forms the execution environment • When compiled to Java byte codes, should run on any instantiation of a Java virtual machine • However, possible problems with different versions
Java Applets • Browsers such as Netscape, Internet Explorer, etc, include a Java virtual machine • Java applets are downloaded from server and run on the browsers virtual machine • Even though they run on the client, Java applets are restricted so that they cannot damage that machine
ActiveX • Developed by Microsoft, ActiveX controls are software objects referenced by a web page • These can be automatically downloaded and installed on a users machine • ActiveX controls have full access to the clients system and so use digital signatures to authenticate their source
Fin Fin