1 / 41

Developing browser based applications [SysReader Programmers Festival ‘97]

Developing browser based applications [SysReader Programmers Festival ‘97]. T.N.C.Venkata Rangan Vishwak Associates Chennai - 600 033 www: http://www.easytools.com email: vishwak@md2.vsnl.net.in Phone: 489 9109. Conventional Front Ends. Powersoft PowerBuilder Oracle forms

aida
Download Presentation

Developing browser based applications [SysReader Programmers Festival ‘97]

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Developing browser based applications [SysReader Programmers Festival ‘97] T.N.C.Venkata Rangan Vishwak Associates Chennai - 600 033 www: http://www.easytools.com email: vishwak@md2.vsnl.net.in Phone: 489 9109 http://www.easytools.com/festival.zip

  2. Conventional Front Ends • Powersoft PowerBuilder • Oracle forms • Microsoft Visual Basic • Borland dBase/Microsoft Foxpro • CA-Clipper • C/C++ • Borland Delphi http://www.easytools.com/festival.zip

  3. Conventional … Advantages • Familiarity and Experience with them • Reliability • Connectivity (with backend databases) http://www.easytools.com/festival.zip

  4. Conventional … Disadvantages • Portability problems • Compatibility problems • Distribution & Installation • Support and TroubleShooting • Complexity to Developers • Inconsistent UI between various Apps. • Restricted navigation for the user • Security on different Modules http://www.easytools.com/festival.zip

  5. Browser based Apps? HTML based Forms + Client/Server Side Programming + Database Source/Server = Browser based Applications http://www.easytools.com/festival.zip

  6. Browser ... Advantages • Consistent UI between different Applications • Familiar browser paradigm of navigation • Internet/Web Standards • Installation • Browsers are inexpensive and some are free http://www.easytools.com/festival.zip

  7. HTML - An Example <HTML> <HEAD> <TITLE>Welcome</TITLE> </HEAD> <BODY> Hello World! </BODY> </HTML> http://www.easytools.com/festival.zip

  8. Client Side Programming The ACTIVE way [Can I say that as the Microsoft way? :-)] ActiveX Controls (.ocx) ActiveX Documents (.vbd) The JAVA Way [Is it the Programming Nirvana? :-)] http://www.easytools.com/festival.zip

  9. What is ActiveX … ??? ActiveX is basically a specification for interfaces between objects. ActiveX Controls makes up the components used to build other applications, whereas ActiveX Documents is the program. ActiveX Documents may be loosely called as a sophisticated Form Object. You don’t, for example, put a bunch of ActiveX Documents on a form, as you do ActiveX controls on it. http://www.easytools.com/festival.zip

  10. Tools to build ActiveX ... • Microsoft Visual Basic 5.0 • Microsoft Visual C++ 4.x or above • Microsoft Visual J++ • Borland Delphi 3.x Tip:VB 5.0 can directly convert your VB 4.0+ forms into ActiveX controls. http://www.easytools.com/festival.zip

  11. ActiveX - Will it run in ...? • ActiveX is supported in IE 3.0 and above • Runs in Navigator 3.x and above provided you have NCompass labs Plug-in installed:-( • Note: • If the ActiveX control or document is developed in VB/VC++/VJ++ you require the respective supporting libraries/DLLs/VM. • ActiveX controls are Auto downloadable ! :-) http://www.easytools.com/festival.zip

  12. Sample HTML with ActiveX <HTML> <HEAD><TITLE>VB Form into ActiveX Control inside browser </TITLE></HEAD> <BODY> <OBJECT ID="UserControl11" WIDTH=557 HEIGHT=442 CLASSID="CLSID:1DDBB7E7-62BB-11D1-AA70-008048FD3FDA"> <PARAM NAME="_ExtentX" VALUE="11790"> <PARAM NAME="_ExtentY" VALUE="9335"> </OBJECT> <H2> I have my VB 5.0 form as an ActiveX control inside IE 4.0 now.</H2> </BODY> </HTML> http://www.easytools.com/festival.zip

  13. http://www.easytools.com/festival.zip

  14. JAVA JAVA: A simple, object-oriented, distributed, interpreted, robust, secure, architecture neutral, portable, high-performance, multi-threaded, and dynamic language. A JAVA Applet is a JAVA program that adheres to a set of conventions that allows it to run within a JAVA-compatible browser. http://www.easytools.com/festival.zip

  15. JAVA - Sample <HTML> <HEAD><TITLE>A Simple Program</TITLE></HEAD> <BODY> Here is the output of my program: <APPLET CODE=“HelloWorld.class” WIDTH=150 HEIGHT=25> </APPLET> </BODY> </HTML> http://www.easytools.com/festival.zip

  16. JAVA - Sample Applet import java.applet.Applet; import java.awt.Graphics; public class HelloWorld extends Applet { public void paint(Graphics g) { g.drawString(&quot;Hello world!&quot;, 50, 25); } } HelloWorld.java http://www.easytools.com/festival.zip

  17. JAVA - Sample Applet http://www.easytools.com/festival.zip

  18. Client Side… Advantages • Easier conversion • Server load is reduced • Interactivity • Reduced Network traffic http://www.easytools.com/festival.zip

  19. Client Side … Disadvantages • Code is visible to users • Limited Portability • Restricted Browser independence • Requires powerful clients http://www.easytools.com/festival.zip

  20. Server Side Programming • Active Server Pages (ASP) • PERL and other CGI tools • Microsoft ISAPI & Netscape NSAPI • JAVA Servers from Sun & Netscape http://www.easytools.com/festival.zip

  21. Server Side Programming http://www.easytools.com/festival.zip

  22. ASP - An Example <HTML> <HEAD> <TITLE>ASP Example</TITLE> </HEAD> <BODY> <% for i=1 to 7 %> <FONT SIZE=<%=i%>>Hello World!</FONT><BR> <% Next %> </BODY> </HTML> http://www.easytools.com/festival.zip

  23. ASP - An Example http://www.easytools.com/festival.zip

  24. ASP - An Example <HTML> <HEAD> <TITLE>ASP Example</TITLE> </HEAD> <BODY> <FONT SIZE=4>Hello World!</FONT><BR> <FONT SIZE=5>Hello World!</FONT><BR> <FONT SIZE=6>Hello World!</FONT><BR> <FONT SIZE=7>Hello World!</FONT><BR> </BODY> </HTML> http://www.easytools.com/festival.zip

  25. Form Processing - HTML (eating.html) <HTML><HEAD><TITLE>Sample Form</TITLE></HEAD> <BODY><CENTER><H1>Late-night programmers eating habits</H1> Check all that apply<P> <TABLE><TR><TD ALIGN=LEFT> <FORM ACTION=”eating.asp" METHOD=POST TARGET="_top"> <INPUT TYPE="CHECKBOX" NAME="chk" value="Pizza">Pizza<BR> <INPUT TYPE="CHECKBOX" NAME="chk" value="Coffee">Coffee<BR> <INPUT TYPE="CHECKBOX" NAME="chk" value="Chips">Chips<P> <INPUT TYPE=SUBMIT VALUE="Submit"> </FORM> </TD></TR></TABLE> </CENTER></BODY></HTML> http://www.easytools.com/festival.zip

  26. Form Processing - HTML (eating.html) http://www.easytools.com/festival.zip

  27. Form Processing - ASP (eating.asp) <HTML> <HEAD> <TITLE>Sample Form Processing</TITLE> </HEAD> <BODY> <CENTER> <H1>Late-night programmers eating habits</H1> Your choices<P> </CENTER> <B>You like:</B><BR><%=Request("chk")%><BR> </BODY> </HTML> http://www.easytools.com/festival.zip

  28. Form Processing - ASP (eating.asp) http://www.easytools.com/festival.zip

  29. ADO Sample Code <HTML> <HEAD><TITLE>Project list</TITLE></HEAD> <BODY> <% '----- Open the database, create the record set Set cn = Server.CreateObject ("ADODB.Connection") cn.Open "dsn=ProjList;database=ProjInfo;uid=;pwd=;" Set rs = cn.Execute ("select ProjName, ProjMgr, DueDate from Projects order by DueDate") http://www.easytools.com/festival.zip

  30. ADO Sample Code Response.Write ("<CENTER><TABLE>") '----- Captions Response.Write ("<TR>") for iCol = 0 to rs.Fields.Count - 1' Response.Write ("<TD><CENTER>") Response.Write (rs(iCol).Name) Response.Write ("</CENTER></TD>") next Response.Write ("</TR>") http://www.easytools.com/festival.zip

  31. ADO Sample Code '----- Data rows do while not rs.eof Response.Write ("<TR>") for iCol = 0 to rs.Fields.Count - 1 Response.Write ("<TD>") Response.Write (rs(iCol)) Response.Write ("</TD>") next Response.Write ("</TR>") rs.MoveNext loop http://www.easytools.com/festival.zip

  32. ADO Sample Code Response.Write ("</TABLE></CENTER>") rs.Close cn.Close %> </BODY> </HTML> http://www.easytools.com/festival.zip

  33. ADO Sample Code http://www.easytools.com/festival.zip

  34. PERL PERL stands for Practical Extraction and Report Language. Larry Wall (creator of PERL) loves to call it Pathologically Eclectic Rubbish Lister http://www.easytools.com/festival.zip

  35. PERL - Advantages • FREE of cost • Popularity • Available for many platforms • Socket Support • Pattern Matching (ideal for searching text) • Flexible Text handling (No details to worry) • Newer packages for Win32 support ODBC http://www.easytools.com/festival.zip

  36. PERL - Sample sub getFormData { my($buffer) = ""; if ($ENV{'REQUEST_METHOD'} eq 'GET') { $buffer = $ENV{'QUERY_STRING'}; } else { read(STDIN, $buffer,$ENV{'CONTENT_LENGTH'}); } } http://www.easytools.com/festival.zip

  37. Server Side… Advantages • Instant Portability-Platform Independence • No manual installation • Easy/Auto Distribution (upgrades too) • Scalability • Runs in thin clients • Data + Code resides only in the Server • Code (Core business logics) are secure • No need of seperate S/W client licenses • No compilation process for ASP & PERL http://www.easytools.com/festival.zip

  38. Server Side… Disadvantages • Learning curve (because of New tools) • Server is overloaded? • Server licenses are expensive • Speed (both ASP & PERL are interpreted) http://www.easytools.com/festival.zip

  39. Decision ? Develop. Ease of development not only means that an application can cost less to develop, it means that the team's skills can be better utilized. Scale. It is possible to build a single application that can be used by virtually any number of users—simultaneously. Maintain. Customer requirements change, businesses change, business needs change and will continue to change while the team adapts existing systems to last week's changes. Deploy. Systems should be easy to install and should easily be upgraded to the newer versions. Use. The application must not only work responsively, it must anticipate user needs, http://www.easytools.com/festival.zip

  40. Reference Books • Programming PERL - Larry Wall • HTML The definitive guide - Musciano & Kennedy • JavaScript Programming - Reaz Hoque • Understanding ActiveX & OLE - David Chappell • Active Visual Basic 5.0 - Eddon & Eddon • The JAVA Tutorial - Campione & Walrath • Unlocking Active Server Pages - Christoph Wille http://www.easytools.com/festival.zip

  41. World Wide Web • www.perl.org • www.activestate.com • www.w3c.org • developer.netscape.com • www.javasoft.com • www.microsoft.com/iis/default.asp • www.microsoft.com/iis/evaluating/guides /whitepapers/aspwp.htm • www.microsoft.com/msdn http://www.easytools.com/festival.zip

More Related