附录 A 外文翻译——原文部分
ASP programming attention several principles
“Active Server Page (ASP)” the application procedure success is decided
frequently in and designs these two aspects to the architecture the choices. Considered
ASP technology scope broad and current application procedure inherent complexity,
this kind of choices are extremely difficult. In this article, will provide some specific
directive for you, I the directive reorganized a group of development principle. When
appraisal solution and technology, may the application following principle help you to
make the decision-making. Following principle is I since long ago from the successful
development pattern obtained experience accumulation.
Principle 1: Uses the standard method
The establishment naming agreement and causes the table of contents structure
standardization, may help you to enhance the ASP application procedure greatly the
readability and the maintainability. Although still did not have the ASP application
procedure at present the de jure standard, many development personnel have
established some general ways. In this, I will share some more general way with you.
Because the ASP technology dependence script engine carries on the work,
moreover the script has the type not strict instinct, the naming agreement very is also
fuzzy. In the type extremely strict language, the variable will defer to its actual type to
carry on the statement. When uses the ASP technology, (but usually defers to the
processing variable the way is not its actual data type) states the variable in the ASP
code. For example, when uses “Visual Basic(R) Scripting Edition (VBScript)”,
although all VBScript variable all is Variant, you can succeed the symbol statement
are bSuccess (b represent Boolean), but is not vSuccess (v represents Variant).
Uses the table of contents structure to provide the constant position as far as
possible for yours each application procedure part. Your application procedure actual
table of contents structure decided certainly by you, but usually is the image, the
documents, the include document and the module lays aside separately in the
independent table of contents. The following is the simple ASP application procedure
table of contents structure demonstration
Principle 2: Under the design for in will serve moves
ASP in to serve moves. When designs the ASP application procedure, you can face
the security environment and the thread question immediately which cannot meet in
the tabletop application procedure. In the tabletop environment, usually only
processes takes the interactive user movement the single thread execution, moreover
is authorized to visit the current tabletop system. In “Internet information service
(IIS)”, the simulation different user environment many client thread transfers your
application procedure, moreover your application procedure is restricted in “the
system” the tabletop.
This meant to you what? Please study IIS the safe mode. Also must remind you:
Because only certain things can under Visual Basic IDE be able the normal operation,
not to mean it can in the ASP technology the safe operation. Visual Basic when IDE
not accurately simulation run environment. The common design includes wrongly: