Adobe Dreamweaver CS3 Manuale Utente Pagina 602

  • Scaricare
  • Aggiungi ai miei manuali
  • Stampa
Vedere la pagina 601
DREAMWEAVER CS3
User Guide
595
The server behavior is listed in the Server Behaviors panel (Window > Server Behavior); click the Plus (+) button to
view the server behavior.
5 Test the server behavior and ensure that it functions properly.
Position a code block relative to another tag on the page
1
In the Insert Code pop-up menu, select Relative To A Specific Tag.
2 In the Tag box, enter the tag or select one from the pop-up menu.
If you enter a tag, dont include the angled brackets (
<>).
3 Specify a location relative to the tag by choosing an option in the Relative Position pop-up menu.
Position a code block relative to a tag selected by the page designer
1
In the Insert Code pop-up menu, select Relative To The Selection.
2 Specify a location relative to the selection by choosing an option in the Relative Position pop-up menu.
Youcaninsertyourcodeblockjustbeforeorjustaftertheselection.Youcanalsoreplacetheselectionwithyourcode
block, or you can wrap the code block around the selection.
Towrapthecodeblockaroundaselection,theselectionmustconsistofanopeningandclosingtagwithnothingin
between, as follows:
<CFIF Day=”Monday”></CFIF>
Inserttheopeningtagpieceofthecodeblockbeforetheselectionsopeningtagandtheclosingtagpieceofthecode
block after the selections closing tag.
Repeating code blocks with the loop directive
To repeat a portion of a code block or the entire code block a number of times, use the following syntax:
<@ loop (@@param1@@,@@param2@@) @>code block<@ endloop @>
When creating server behaviors, you can use looping constructs to repeat a code block a specified number of times.
<@ loop (@@param1@@,@@param2@@,@@param3@@,@@param_n@@) @>code block
<@ endloop @>
The loop directive accepts a comma-separated list of parameter arrays as arguments. In this case, parameter array
arguments allow a user to supply multiple values for a single parameter. The repeating text is duplicated n times,
where n is the length of the parameter array arguments. If more than one parameter array argument is specified, all
the arrays must have the same length. On the ith evaluation of the loop, the ith elements of the parameter arrays
replace the associated parameter instances in the code block.
When you create a dialog box for the server behavior, you can add a control to the dialog box that lets the page
designer create parameter arrays. Dreamweaver includes a simple array control that you can use to create dialog
boxes. This control, called Text Field Comma Separated List, is available through the Server Behavior Builder. To
create user interface elements of greater complexity, see the API documentation to create a dialog box with a control
to create arrays (a grid control, for example).
You can nest any number of conditionals or a loop directive within a conditional directive. For example, you can
specify that if an expression is true to execute a loop.
The following example shows how such repeating code blocks can be used to create server behaviors (the example is
a ColdFusion behavior used to access a stored procedure):
September 4, 2007
Vedere la pagina 601
1 2 ... 597 598 599 600 601 602 603 604 605 606 607 ... 737 738

Commenti su questo manuale

Nessun commento

EVOC Motherboards user manuals

The list of EVOC Motherboards products contains 4 user manuals for 3 models. All pdf user’s guides are available for download or viewing online.

Click on an alphabet below to scroll to the full list of models starting with that letter

Models Document Type
EC0-1815V2NAR
User Manual   EVOC EC0-1815V2NAR User manual, 56 pages
EC3-1813 Series
User Manual    EVOC EC3-1813 Series User manual, 101 pages
User Manual   EVOC EC3-1813 Series User manual, 51 pages
EC7-1817LNAR
User Manual   EVOC EC7-1817LNAR User manual, 59 pages