This is part of my summary of the content of SOM, I hope you can discuss, and some of the content is not very sure, hope you correct me.

Source: Internet
Author: User
Tags html form object model variable scope
VI 1.0 era:
1. server-side:asp Script
are surrounded by <%%>. ----the so-called inline way.
In the page, executes from top to bottom.
The variable scope is a page.
Used to insert an expression, such as: <% =myvar%>.
<% = xxx%> equivalent to <% Response.Write xxx%>

2. client-side:dhtml, Document Object Model
Object objects of the DOM model contain:
A. Page model: window.document.xxx
B. Form elements: such as: Button, ListBox, etc
C. ActiveX controls
Interoperate with Client-side script only
data-binding function refers to the client-side parts can be binding with the recordset in Client-side cache (through RDS/TDC implementation).

3. Most applications take: HTML form submission, call ASP page, write ASP script in ASP page.

=======================================================================================

VI 6.0 era:
1. ASP script (in addition to the above content)
Use
<script runat=server>
Function MyFunc
Xxxx
End Function
</script>
The variable scope is a function.
Called in event-driven mode.

2. client-side:dhtml, Document Object Model (same as above)

3. In addition to the above model, the Script object model is provided, combining the client-side with the Server-side model.
Basic principle:
A. The introduction of the Script object concept. (usually generated by DTC, design time Control)
Although in principle form elements, ActiveX control, server object is script object, in order to achieve simultaneous server-side
Script and Client-side script support, it is best to use the DTC in Vi6 to generate script object.
B. Write event handler for script object you can use Server-side script and Client-side script.
C. Script object model is implemented by the script library that is automatically generated by Web project.

DTC Fundamentals:
A. As before, the DTC is first: The Programming Wizard, the Code Auto Generator (design-time).
Automatically generated code (text) (run-time) can be called: Script Object, which may contain:
Html
Form (elements)
ActiveX Control
Server Component
Script

B. In Design-time:
Design-time has attributes, change the DTC Edit Properties dialog box options, we actually change the DTC automatically generated code.
Design-time has no concept of method and event.
C. DTC generated code Runtime: (ie: script object in Run-time)
The script object has the concept of attributes, which is different from the DTC property in Design-time, but it has a certain connection.
The script object has the concept of method and event.
Again, the script object generated by DTC can use both Server-side script and Client-side script.

Or, in strict terms, the Target platform of the script object can be selected.
Server:
The script Object is generated by the server script.
Event is handled by the server script.
The Data binding occurs on the Server.
Visible only to the Server environment.

Client:
The script Object is generated by the Client script.
The Event is handled by the Client script.
The Data binding can occur on both Client and server.
Visible only to the client environment.

Because Page object can reference pages to server/client, it can be a bridge between server/client.



Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.