I created a CustomTemplate to share with Add, Edit and View.The page look good in Add and Edit page.But when in View, the layout all handle by table > tr > td, no more with textarea and so on…My question is, how to preserve the layout like the customtemplete?Thanks in advance.
scs
It is the same. When you use Custom Template, the original layout is hidden, it doesn’t matter if it is
CustomTemplate for both Edit and View Page
<div class="row">
<div class="col-sm-6 bg-secondary bg-opacity-10">{{{value remarks}}}</div>
</div>
in edit,
<div class="row">
<div class="col-sm-6"><span id="el_trxs_remarks">
<textarea data-table="trxs" data-field="x_remarks" name="x_remarks" id="x_remarks" cols="30" rows="3" placeholder="" class="form-control sr_noresize" readonly="1" aria-describedby="x_remarks_help">Min: 3.3233
Std: 3.3233
Max: 3.3233</textarea>
<div class="invalid-feedback"></div>
</span></div>
</div>
in view,
<div class="row">
<div class="col-sm-6 bg-secondary bg-opacity-10"><span id="el_trxs_remarks">
<span>
Min: 3.3233<br>Std: 3.3233<br>Max: 3.3233</span>
</span></div>
</div>
The textarea no more available in view
scs wrote:
CustomTemplate for both Edit and View Page
The {{{value remarks}}} means the original generated code.
phpmaker standard view will show screen like
| col-3 | col-9 | <= CSS
| Remarks | multiple lines remarks |
| Addtional | multiple lines additional information |
I modify the CustomTemplate to view like
| col-6 | col-6 | <= CSS
| Remark | Addtional |
| multiple lines remarks | multiple lines additional information |
Thats why the customtemplate look like the original code.in edit,
it will show
But in view, it become
remarks
additional information
arbei wrote:
The > {{{value remarks}}} > means > the original generated code
Read Custom Templates → Custom Template Tags → Important note:
Remember that Custom Template is rearrangement of existing HTML fragments in the page. Most of the following tags output HTML markup for the field in the page…