web engineering 2(lect 0)

35
Web Engineering-II Web Engineering-II By; By; Roohul Amin Mashwani Roohul Amin Mashwani

Upload: roohul-amin

Post on 07-May-2015

3.480 views

Category:

Technology


1 download

TRANSCRIPT

Page 1: Web engineering 2(lect 0)

Web Engineering-IIWeb Engineering-II

By;By;

Roohul Amin MashwaniRoohul Amin Mashwani

Page 2: Web engineering 2(lect 0)

IntroductionIntroduction► ROOHUL AMIN MASHWANIROOHUL AMIN MASHWANI

LecturerLecturer

► MSc. Computer ScienceMSc. Computer Science University of PeshawarUniversity of Peshawar

► Bachelor of Education (B.Ed.)Bachelor of Education (B.Ed.) University of PeshawarUniversity of Peshawar

► Worked As HOD & Lecturer for 3 YearsWorked As HOD & Lecturer for 3 Years Maiwand Institute of Higher EducationMaiwand Institute of Higher Education

Page 3: Web engineering 2(lect 0)

WHY THIS COURSE???WHY THIS COURSE???

►Enable the students to deal with web Enable the students to deal with web applicationapplication

►Learn the techniques for using design Learn the techniques for using design and developing toolsand developing tools

►Ability to build real world web Ability to build real world web application(website)application(website)

►Ability to manipulate databases on serverAbility to manipulate databases on server►Ability to create web presentation Ability to create web presentation ►Ability to use ASP.NET Using VB.NETAbility to use ASP.NET Using VB.NET

Page 4: Web engineering 2(lect 0)

Marks Allotment Marks Allotment SchemeScheme

Mid Term ExamMid Term Exam :: 2525

Quizzes, Assignments, ProjectsQuizzes, Assignments, Projects :: 2020

Class Interest, AttendanceClass Interest, Attendance :: 0505

Terminal ExamTerminal Exam :: 25 + 25 = 5025 + 25 = 50

Total MarksTotal Marks :: 100100

Passing MarksPassing Marks :: 6060

Page 5: Web engineering 2(lect 0)

What Is the World Wide What Is the World Wide Web?Web?

► The World Wide Web—the Web, for short—is The World Wide Web—the Web, for short—is a network of,computers able to exchange a network of,computers able to exchange text, graphics, and multimedi information text, graphics, and multimedi information via the Internet. via the Internet.

► By sitting at a computer that is attached to By sitting at a computer that is attached to the Web, using either a dialup phone line or the Web, using either a dialup phone line or a much faster broadband (Ethernet, cable, a much faster broadband (Ethernet, cable, or DSL connection), you can visit Web-or DSL connection), you can visit Web-connected computers next door, at a nearby connected computers next door, at a nearby university, or halfway around the world. university, or halfway around the world.

Page 6: Web engineering 2(lect 0)

Cont…Cont…

► And you can take full advantage of the And you can take full advantage of the resources these computers make available, resources these computers make available, including text, graphics, videos, sounds, and including text, graphics, videos, sounds, and animation. animation.

► Think of the Web as the multimedia version Think of the Web as the multimedia version of the Internet, and you’ll be right on the of the Internet, and you’ll be right on the mark.mark.

Page 7: Web engineering 2(lect 0)

Cont…Cont…

►When the Web server receives the When the Web server receives the requested information, it looks for this requested information, it looks for this information within its file system, and sends information within its file system, and sends out the requested information via the out the requested information via the Internet.Internet.

► They all speak a common “language,” called They all speak a common “language,” called HyperText Transfer Protocol (HTTP). (HTTP HyperText Transfer Protocol (HTTP). (HTTP isn’t really a language like the ones people isn’t really a language like the ones people speak.speak.

Page 8: Web engineering 2(lect 0)

Cont…Cont…

► It’s a set of rules or procedures, called It’s a set of rules or procedures, called protocols, protocols, that enables computers to that enables computers to exchange information over the Web.) exchange information over the Web.) Regardless of where these computers Regardless of where these computers reside—China, Norway, or reside—China, Norway, or Austin,Texas—they can communicate Austin,Texas—they can communicate with each other through HTTP.with each other through HTTP.

Page 9: Web engineering 2(lect 0)

How Does the Web Work?How Does the Web Work?

► The computers that make all these Web The computers that make all these Web pages available are called pages available are called Web serversWeb servers..

►On any computer that’s connected to the On any computer that’s connected to the Web, you can run an application called a Web, you can run an application called a Web browser.Web browser.

► Technically, a Web browser is called a Technically, a Web browser is called a Web Web clientclient—that is, a program that’s able to —that is, a program that’s able to contact a Web server and request contact a Web server and request information.information.

Page 10: Web engineering 2(lect 0)

How Does HTTP Works?How Does HTTP Works?

►Most Web pages contain hyperlinks, which are specially formatted words or phrases that enable you to access another page on the Web. Although the hyperlink usually doesn’t make the address of this page visible, it contains all the information needed for your computer to request a Web page from another computer.

Page 11: Web engineering 2(lect 0)

Cont…Cont…

►When you click the hyperlink, your computer sends a message called an HTTP request. This message says, in effect, “Please send me theWeb page that I want.”

► The Web server receives the request, and looks within its stored files for the Web page you requested. When it finds the Web page, it sends it to your computer, and your Web browser displays it. If the page isn’t found, you see an error message, which probably includes the HTTP code for this error: 404, “Not Found.”

► See the figure

Page 12: Web engineering 2(lect 0)

Figure: To illustrate that Figure: To illustrate that How HTTP Works?How HTTP Works?

HTTP request

Returns page or error message

Client computer running browser Server

The client requests the page. Then the server evaluatesthe request and serves the page or an error message.

Page 13: Web engineering 2(lect 0)

What Is Hypertext/Markup?

►Hypertext is a type of text that contains hyperlinks (or just links for short), which enable the reader to jump from one hypertext page to another.

►A hypermedia system works just like hypertext, except that it includes graphics, sounds, videos, and animation as well as text.

Page 14: Web engineering 2(lect 0)

Cont…Cont…

►HTML consists of its own set of funny-looking symbols that tell Web browsers how to display the page. These symbols, called elements, include the ones needed to create hyperlinks.

►e.g; <a href=“aboutus.html”>About Us</a>

Page 15: Web engineering 2(lect 0)

What is HTML?What is HTML?

►HTML, or HyperText Markup Language, has HTML, or HyperText Markup Language, has two essential features two essential features hypertexthypertext and and universality.universality. Hypertext means you can Hypertext means you can create a link in a Web page that leads the create a link in a Web page that leads the visitor to any other Web page or to visitor to any other Web page or to practically anything else on the Internet.practically anything else on the Internet.

► It means that the information on the Web It means that the information on the Web

can be accessed from many different can be accessed from many different directions. directions.

Page 16: Web engineering 2(lect 0)

Cont…Cont…

►HTML and HTTP were both invented by Tim Berners-Lee, who was then working as a computer and networking specialist at a Swiss research institute.

►Tim Berners-Lee, the creator of the Web, wanted it to work more like a person's brain and less like a static source of data, such as a book.

Page 17: Web engineering 2(lect 0)

Cont…Cont…

► Universality means that because HTML Universality means that because HTML documents are saved as Text Only files, documents are saved as Text Only files, virtually any computer can read a Web page. virtually any computer can read a Web page.

► It doesn't matter if your visitors have It doesn't matter if your visitors have Macintosh or Windows machines, or whether Macintosh or Windows machines, or whether they're on a Unix box or even a they're on a Unix box or even a handheld handheld devicedevice like a Palm. like a Palm.

► The Web is open to all. The Web is open to all.

A computer small enough to be held in one hand while being operated by the other hand. Handheld computers are commonly used in transportation and other field service industries.

PDA

Page 18: Web engineering 2(lect 0)

What Is CSS?

►Stands for Cascading Style Sheets.

►CSS is one of the simplest and most convenient tools available to web developers.

►W3C developed Cascading Style Sheets (CSS).

Page 19: Web engineering 2(lect 0)

Cont…Cont…

► In brief, CSS enables Web authors to specify presentation information without violating the structure versus presentation distinction.

►The style sheet lists the presentation styles that the browser should use to display the various components of the document, such as headings, lists, and paragraphs.

►Without CSS, you’d have to make changes to the presentation code in each and every page.

Page 20: Web engineering 2(lect 0)

What Is XHTML?

►Extensible HTML: features added to HTML 4.0

►Now that you know a little about what XML is, you’re ready to understand what XHTML is. Just as HTML is a markup language defined in SGML, XHTML is a markup language defined in XML.

Page 21: Web engineering 2(lect 0)

What Is PHP?What Is PHP?

► PHP stands for PHP stands for Hypertext PreprocessorHypertext Preprocessor and and is a server-side language. is a server-side language.

► This means that the script is run on your This means that the script is run on your web server, not on the user's browser, so web server, not on the user's browser, so you do not need to worry about you do not need to worry about compatibility issues. compatibility issues.

► PHP is relatively new (compared to PHP is relatively new (compared to languages such as Perl (CGI) and Java) but is languages such as Perl (CGI) and Java) but is quickly becoming one of the most popular quickly becoming one of the most popular scripting languages on the internet. scripting languages on the internet.

Page 22: Web engineering 2(lect 0)

Why PHP? Why PHP?

► Learning a scripting language, or even Learning a scripting language, or even understanding one, can open up huge new understanding one, can open up huge new possibilities for your website. possibilities for your website.

► Although you can download pre-made Although you can download pre-made scripts from sites like Hotscripts, these will scripts from sites like Hotscripts, these will often contain advertising for the author or often contain advertising for the author or will not do exactly what you want. will not do exactly what you want.

Page 23: Web engineering 2(lect 0)

Cont…Cont…

► With an understanding of a scripting language With an understanding of a scripting language you can easily edit these scripts to do what you can easily edit these scripts to do what you want, or even create your own scripts. you want, or even create your own scripts.

► Using scripts on your website allows you to Using scripts on your website allows you to add many new 'interactive' features like add many new 'interactive' features like feedback forms, guestbooks, message boards, feedback forms, guestbooks, message boards, counters and even more advanced features counters and even more advanced features like portal systems, content management, like portal systems, content management, advertising managers etc. advertising managers etc.

Page 24: Web engineering 2(lect 0)

Cont…Cont…

►With these sort of things on your website With these sort of things on your website you will find that it gives a more you will find that it gives a more professional image. professional image.

► As well as this, anyone wanting to work in As well as this, anyone wanting to work in the site development industry will find that the site development industry will find that it is much easier to get a job if they know a it is much easier to get a job if they know a scripting language. scripting language.

Page 25: Web engineering 2(lect 0)

ASP.NETASP.NET► ASP.NET is a framework for building web sites ASP.NET is a framework for building web sites

and web applications. and web applications. 

► ASP.NET is a technology for building ASP.NET is a technology for building powerful, dynamic Web applications and is powerful, dynamic Web applications and is part of the .NET Framework.part of the .NET Framework.

► .NET is language independent, which means .NET is language independent, which means you can use any .NET supported language to you can use any .NET supported language to make .NET applications.make .NET applications.

Page 26: Web engineering 2(lect 0)

ASP.NET Continued….ASP.NET Continued….

► The most common languages for writing The most common languages for writing ASP.NET applications are C# and VB.NET.ASP.NET applications are C# and VB.NET.

► ASP.NET ASP.NET Web Pages Web Pages and the new Razor and the new Razor syntax provide a fast and lightweight way to syntax provide a fast and lightweight way to combine server code with HTML to create combine server code with HTML to create dynamic web content.dynamic web content.

► You can connect to databases, add video You can connect to databases, add video and graphics, include social networking and and graphics, include social networking and add many more features using the latest add many more features using the latest web standards.web standards.

Page 27: Web engineering 2(lect 0)

ASP.NET Continued….ASP.NET Continued….

►With ASP.NET With ASP.NET Web Forms Web Forms you use drag-and-you use drag-and-drop design to build dynamic event-driven drop design to build dynamic event-driven websites.websites.

► Choose from hundreds of controls and Choose from hundreds of controls and components to rapidly build user-driven components to rapidly build user-driven sites with full data accesssites with full data access..

Page 28: Web engineering 2(lect 0)

ASP.NET is NOT ASPASP.NET is NOT ASP

►Microsoft's previous server side scripting Microsoft's previous server side scripting technology ASP 3.0 was the last version of ASP.technology ASP 3.0 was the last version of ASP.

► ASP.NET is the next generation ASP, but it's not ASP.NET is the next generation ASP, but it's not an upgraded version of ASP.an upgraded version of ASP.

► ASP.NET is an entirely new technology for ASP.NET is an entirely new technology for server-side scripting. It was written from the server-side scripting. It was written from the ground up and is not backward compatible with ground up and is not backward compatible with ASP.ASP.

► ASP.NET has better language support, a large ASP.NET has better language support, a large set of new controls, XML-based components, set of new controls, XML-based components, and better user authentication.and better user authentication.

Page 29: Web engineering 2(lect 0)

ASP.NET is NOT ASP ASP.NET is NOT ASP Conti…..Conti…..

►One of the main differences between ASP.NET and One of the main differences between ASP.NET and Classic ASP/PHP is the fact that ASP.NET is Classic ASP/PHP is the fact that ASP.NET is compiled, while ASP is always interpreted. PHP can compiled, while ASP is always interpreted. PHP can be compiled by using commercial products, but be compiled by using commercial products, but usually it's interpreted as well. usually it's interpreted as well. 

► ASP.NET provides increased performance by ASP.NET provides increased performance by running compiled code.running compiled code.

► The first request for an ASP.NET page on the The first request for an ASP.NET page on the server will compile the ASP.NET code and keep a server will compile the ASP.NET code and keep a cached copy in memory. The result of this is cached copy in memory. The result of this is greatly increased performance.greatly increased performance.

Page 30: Web engineering 2(lect 0)

What is ASP.NET?What is ASP.NET?ASP.NET is a server side scripting technology that ASP.NET is a server side scripting technology that enables scripts (embedded in web pages) to be enables scripts (embedded in web pages) to be executed by an Internet server.executed by an Internet server.►ASP.NET is a Microsoft TechnologyASP.NET is a Microsoft Technology►ASP stands for Active Server PagesASP stands for Active Server Pages►ASP.NET is a program that runs inside IISASP.NET is a program that runs inside IIS►IIS (Internet Information Services) is Microsoft's IIS (Internet Information Services) is Microsoft's Internet serverInternet server►IIS comes as a free component with Windows serversIIS comes as a free component with Windows servers►IIS is also a part of Windows 2000 and XP Professional.IIS is also a part of Windows 2000 and XP Professional.

Page 31: Web engineering 2(lect 0)

What is an ASP.NET File?What is an ASP.NET File?

► An ASP.NET file is just the same as an An ASP.NET file is just the same as an HTML fileHTML file

► An ASP.NET file can contain HTML, XML, An ASP.NET file can contain HTML, XML, and scriptsand scripts

► Scripts in an ASP.NET file are executed Scripts in an ASP.NET file are executed on the serveron the server

► An ASP.NET file has the file extension An ASP.NET file has the file extension ".aspx"".aspx"

Page 32: Web engineering 2(lect 0)

How Does ASP.NET Work?How Does ASP.NET Work?

►When a browser requests an HTML file, When a browser requests an HTML file, the server returns the filethe server returns the file

►When a browser requests an ASP.NET When a browser requests an ASP.NET file, IIS passes the request to the file, IIS passes the request to the ASP.NET engine on the serverASP.NET engine on the server

► The ASP.NET engine reads the file, line The ASP.NET engine reads the file, line by line, and executes the scripts in the by line, and executes the scripts in the filefile

► Finally, the ASP.NET file is returned to the Finally, the ASP.NET file is returned to the browser as plain HTMLbrowser as plain HTML

Page 33: Web engineering 2(lect 0)

New in ASP.NETNew in ASP.NET► Better language supportBetter language support► Programmable controlsProgrammable controls► Event-driven programmingEvent-driven programming► XML-based componentsXML-based components► User authentication, with accounts and rolesUser authentication, with accounts and roles► Higher scalabilityHigher scalability► Increased performance - Compiled codeIncreased performance - Compiled code► Easier configuration and deploymentEasier configuration and deployment► Not fully ASP compatibleNot fully ASP compatible

Page 34: Web engineering 2(lect 0)

Language SupportLanguage Support

►ASP.NET uses ADO.NET.ASP.NET uses ADO.NET.►ASP.NET supports full Visual Basic, not ASP.NET supports full Visual Basic, not

VBScript.VBScript.►ASP.NET supports C# (C sharp) and ASP.NET supports C# (C sharp) and

C++.C++.►ASP.NET supports JScript.ASP.NET supports JScript.

Page 35: Web engineering 2(lect 0)

Thank You All!