|
36 | 36 | <form id="vstobjects" method="POST" name="v_setup_webapp" style="padding-top:0px;" > |
37 | 37 | <input type="hidden" name="token" value="<?=$_SESSION['token']?>" /> |
38 | 38 | <input type="hidden" name="ok" value="true" /> |
| 39 | + |
| 40 | + <?php if( !$WebappInstaller->isDomainRootClean()): ?> |
| 41 | + <span class="alert alert-info alert-with-icon"> |
| 42 | + <i class="fas fa-info"></i> |
| 43 | + <?=__('Data loss warning!<br>Your web domain already has files uploaded, the installer will overwrite your files and/or the installation might fail.<br/><br/> Please use the installer only for empty web domains')?> |
| 44 | + </span> |
| 45 | + <br/> |
| 46 | + <?php endif ?> |
| 47 | + |
39 | 48 | <div class="app-form" > |
40 | 49 | <?php foreach ($WebappInstaller->getOptions() as $form_name => $form_control):?> |
41 | 50 | <?php |
42 | 51 | $f_name = $WebappInstaller->formNs() . '_' . $form_name; |
43 | 52 | $f_type = $form_control; |
44 | 53 | $f_value = ''; |
45 | 54 | $f_label = ucwords(str_replace(['.','_'], ' ', $form_name)); |
| 55 | + $f_placeholder = ''; |
46 | 56 | if (is_array($form_control)) { |
47 | 57 | $f_type = (!empty($form_control['type']))?$form_control['type']:'text'; |
48 | 58 | $f_value = (!empty($form_control['value']))?$form_control['value']:''; |
| 59 | + $f_placeholder = (!empty($form_control['placeholder']))?$form_control['placeholder']:''; |
49 | 60 | } |
50 | 61 |
|
51 | 62 | $f_value = htmlentities($f_value); |
52 | 63 | $f_label = htmlentities($f_label); |
| 64 | + $f_placeholder = htmlentities($f_placeholder); |
53 | 65 | ?> |
54 | 66 | <div class="form-group"> |
55 | 67 | <label style="padding-bottom: 2px;" for="<?=$f_name?>"><?=$f_label?> |
|
70 | 82 | <?php elseif (in_array($f_type, ['boolean'])):?> |
71 | 83 | <p> |
72 | 84 | <?php $checked = (!empty($f_value))?'checked':''?> |
73 | | - <input style="width:auto;" type="checkbox" class="vst-input" name="<?=$f_name?>" id="<?=$f_name?>" <?=$checked?> value="true"> |
| 85 | + <input style="width:auto;" type="checkbox" class="vst-input" name="<?=$f_name?>" id="<?=$f_name?>" <?=$checked?> value="true"> |
74 | 86 | </p> |
75 | 87 | <?php else:?> |
76 | 88 | <p style="margin-top:0;"></p> |
77 | | - <input type="text" size="20" class="vst-input" name="<?=$f_name?>" id="<?=$f_name?>" value="<?=$f_value?>"> |
| 89 | + <input type="text" size="20" class="vst-input" name="<?=$f_name?>" id="<?=$f_name?>" placeholder="<?=$f_placeholder?>" value="<?=$f_value?>"> |
78 | 90 | </p> |
79 | 91 | <?php endif?> |
80 | 92 | </div> |
|
0 commit comments