01.12.2012 Views

7 Components: the Function Pages - Developers

7 Components: the Function Pages - Developers

7 Components: the Function Pages - Developers

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Formatting<br />

tables<br />

Fig. 19.8<br />

Fig. 19.9<br />

292<br />

��<br />

��<br />

��<br />

19.6.1<br />

Formatting <strong>the</strong> Entire Table<br />

To create an editable table, first set <strong>the</strong> variable<br />

%EDITTABLE{...}% in <strong>the</strong> corresponding place or insert <strong>the</strong><br />

variable directly before an existing table. The parameters are now<br />

defined within <strong>the</strong> brackets for <strong>the</strong> edit view of <strong>the</strong> table.<br />

Here is a very simple table with only two parameters as an example:<br />

%EDITTABLE{ ↵<br />

format="| row, -1 | text, 20, init | ↵<br />

select, 1, one, two, three, four | ↵<br />

label, 0, %SERVERTIME{"$day $mon $year ↵<br />

$hour:$min"}% |" ↵<br />

changerows="on" ↵<br />

}%<br />

|*No*|*Text Field*|*Drop-Down Menu* ↵<br />

|*Time Stamp*|<br />

| 1 | init | two | 07 Jan 2005 14:55 |<br />

The page view <strong>the</strong>n looks like this:<br />

The same in <strong>the</strong> edit mode of <strong>the</strong> table looks like this:<br />

In <strong>the</strong> %EDITTABLE% variable, <strong>the</strong> input options of our table were<br />

first defined. Then we entered <strong>the</strong> content of two lines, namely <strong>the</strong><br />

header and <strong>the</strong> first line, directly in <strong>the</strong> code, although it is not necessary<br />

to fill <strong>the</strong> table with content at <strong>the</strong> code level. However, <strong>the</strong><br />

user should at least get an explanation if he or she sees an Edit button<br />

but no table.<br />

19 Composing <strong>the</strong> Project Plan

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!