Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.

ملخص تقنية تصميم صفحات الويب - الوحدة السادسة

563 views

Published on

ملخص تقنية تصميم صفحات الويب - الوحدة السادسة
كلية التكنولوجيا والعلوم التطبيقية
جامعة القدس المفتوحة

Published in: Education
  • Be the first to comment

  • Be the first to like this

ملخص تقنية تصميم صفحات الويب - الوحدة السادسة

  1. 1. Web Sites Web Sites Static Web Sites2-tier Dynamic Web Sites3-tier BrowserWeb Server 2
  2. 2. First TierFORMSecond TierASPThird TierDatabase Three Tiers OLE-DBODBC ASPUNIVERSAL DATA ACCESS-UDA 3
  3. 3. 4 OLEDBDATA SOURCERELATIONAL NON RELATIONALUDA. OLEDB ADOOLEDBObjects
  4. 4. ActiveX Data Object-ADOObjects ADODATA ACCESS OBJECT DAOVB++VISUAL C. 5
  5. 5. Data Source Name DSN DSNJETACCESSWindows. DSN -File DSN:Text File -System DSN:Windows Registry -USER DSN:Windows RegistryUSER DSN 6
  6. 6. SQL SQL SQL SQL Select -Insert -Delete -Update 7
  7. 7. SELECTSELECT*SQLEmp: SELECT * From Emp FirstNameLastNameEmpSQL SELECT FirstName, LastName From Emp SELECT* Data FilteringSQLWHERE  WHERE Data-Comparison 8
  8. 8. WHERE BETWEEN: IN: LIKE: BETWEENSQLRecord setSQLFirstNameQV: SELECT * FROM Users WHERE FirstName BETWEEN 'Q' AND 'V' BETWEENSQLTaxRate57: SELECT * FROM Customers WHERE TaxRate BETWEEN 5 AND 7 9
  9. 9. INSQL SELECT * FROM Customers WHERE City IN 'Amman','Irbid' LIKE. 1SQLS: SELECT * FROM Customers WHERE FirstName LIKE 'S*' 2.SQLSM: SELECT * FROM Customers WHERE FirstName LIKE '[S,M]*' 3.SQLSa: SELECT * FROM Customers WHERE FirstName LIKE 'Sa*' 4.SQL2029: SELECT * FROM Customers WHERE Age LIKE '2*' 10
  10. 10. 5SQLABC: SELECT * FROM Customers WHERE FirstName LIKE '[A-C]*'    11
  11. 11. WHERE.29/2/2000SQL SELECT * FROM Users WHERE RecordCreationDate >= #29/2/2000# # INSERT. INSERT INTO EMP (Empno, ename, sal) VALUES (2323,"Ali", 2000) 12
  12. 12. DELETESQLTableName: DELETE From TableName WHERESQL DELETE FROM Customers WHERE AcountBalance=0 UPDATE. 232320% Update EMP Set sal=sal*1.2 Where Empno=2323 13
  13. 13. ActiveX Data Object - ADO ASPADODSNADO 1CONNECTION OBJECT. 2OPEN CONNECTION 3SQL 4CLOSE CONNECTIONSelect. 14
  14. 14. ActiveX Data Object - ADO Connection Object ConnectionConnection ObjectADOConnection ObjectApplication Server. OpenClose 15
  15. 15. Connection Object 16
  16. 16. Connection Object 2 3ConnectionADO CreateObject""ServerASP. 4OpenDSN filedsl  5Close 17
  17. 17. Connection object 18
  18. 18. Connection ObjectProperties Object 19
  19. 19. Recordset Object Recordset Object RecordsRecordset Object Recordset Object. 20
  20. 20. New InstanceConnection objectRecordset Object2345SQLSqlcom. open635conn7eofTrueFalse 8HTMLfname9MoveNext10Close. 21
  21. 21. PropertiesMethods OPEN:SQL STATEMENTCONNECTION OBJECT. CLOSE: MOVE:RECORDSET OBJECT MOVENEXT: MOVEPREVIOUS:MOVENEXT 22
  22. 22. 6.MOVEFIRST: 7.MOVELAST:MOVEFIRST 8.ADDNEW:RECORDSET 9.UPDATE:RECORDSETADDNEW 10.DELETE: 23
  23. 23. Recordset Recordset -EOF END OF FILE:RECORDSETTRUEFALSE -BOF BEGINNING OF FILE:TRUEfalse -MAXRECO:OPENOPENOPENRECORDSET OBJECT. 24
  24. 24. COLLECTION -PROPERITIES: … set rset=server.createobject"ADODB.Recordset" … rset.properites"status"; -FIELDS:SQL. rset"fname"; 25
  25. 25. Commands Object Commands Object SQLSTORED PROCEDURE. MethodsProperties -Active Connection:Connection Object. set commobj = server.createobject"adodb.command" commobj.ActiveConnection=conn conn 26
  26. 26. Command Text:sqlStored Procedure. Sqlcomm="insert into student StudentNo, fname values 101010,’Ali’;" commobj.CommandText=sqlcomm commobj -Prepared:CommandTextsql Commobj.Prepared = true; 27
  27. 27. Methods -CreateParameter:ParameterCommand ObjectParametersqlStored Procedure. -Execute:CommandText. Commobj.Execute; commobj 28
  28. 28. Collection -Properties: -Parameter:ParametersqlStored Procedure. 29
  29. 29. Parameter Commobj.Parameters.Append commobj.createParameter"name" commobjParametersParameter ObjectAppendCreate Parametername. sqlsql Sqlstatment="insert into student )sno, fname( values )?, ?( " Create Parametersql 30
  30. 30. Example 1 <html> <body> <form name="form1" method=post action="program.asp"> <input type="text" name="first"> <input type="text" name="number"> <input type="submit" value="send data"> </body> </form> </html> 31
  31. 31. HTMLprogram.asp 32
  32. 32. Example 2 ASPVBScriptJavaScriptVBScripASP studentinfostudnostudnamestudmajor. 33
  33. 33. Dim:. ConnectionString:student.mdb Set Conn1:Conn1. studconn.txtinclude Conn1.open: 34
  34. 34. 35
  35. 35. 1 2select SQL:Selectstudentinfo. :3set rs:. studnostudnamestudmajorresponse.write 36
  36. 36. FormActionASPAction -Post -Get TextboxFormAction 37
  37. 37. Select: 38
  38. 38. 1 2studnostudnamestudmajor. :3 39
  39. 39. keywordSQLkeyword 40
  40. 40. 1 2AilAli. 41

×