PHP Classes

File: src/Cabin/Bridge/config/editor_templates/cabin_config.twig

Recommend this page to a friend!
  Classes of Scott Arciszewski   CMS Airship   src/Cabin/Bridge/config/editor_templates/cabin_config.twig   Download  
File: src/Cabin/Bridge/config/editor_templates/cabin_config.twig
Role: Auxiliary data
Content type: text/plain
Description: Auxiliary data
Class: CMS Airship
Content management system with security features
Author: By
Last change: Form UI/UX enhancements
Begin v1.3.0
Date: 7 years ago
Size: 11,919 bytes
 

Contents

Class file image Download
{% if not form_key_config %}{% set form_key_config = "config_extra" %}{% endif %} {% if not form_key_twig %}{% set form_key_twig = "twig_vars" %}{% endif %} <div class="table table-pad-1 full-width"> <div class="table-row"> <div class="table-min-width table-pad-right text-right table-cell align-top"> <label for="twigvars_active_motif"> {{ __("Active Motif")|e('html') }}: </label> </div> <div class="table-cell full-width"> <select class="full-width" id="twigvars_active_motif" name="{{ form_key_twig }}[active-motif]" >{% for name, motif in motifs %} <option value="{{ name|e('html_attr') }}"> {% if motif.config["display_name"] %} {{ motif.config["display_name"]|e('html') }} {% else %} {{ motif.config.supplier|e('html') ~ "/" ~ motif.config.name|e('html') }} {% endif %}</option> {% endfor %}</select> </div> </div> <div class="table-row"> <div class="table-min-width table-pad-right text-right table-cell align-top"> <label for="twigvars_title"> {{ __("Page Title")|e('html') }}: </label> </div> <div class="table-cell full-width"> <input class="full-width" id="twigvars_title" type="text" name="{{ form_key_twig }}[title]" value="{{ twig_vars['title']|e('html_attr') }}" /> </div> </div> <div class="table-row"> <div class="table-min-width table-pad-right text-right table-cell align-top"> <label for="editor_default"> {{ __("Default Format")|e('html') }}: </label> </div> <div class="table-cell full-width"> <select class="full-width" id="editor_default" name="{{ form_key_config }}[editor][default-format]" > <option value="HTML" {% if config_extra['editor']['default-format'] == 'HTML' %} selected="selected" {% endif %} >{{ __("Raw HTML") }}</option> <option value="Markdown" {% if config_extra['editor']['default-format'] == 'Markdown' %} selected="selected" {% endif %} >{{ __("Markdown") }}</option> <option value="Markdown" {% if config_extra['editor']['default-format'] == 'Rich Text' or not config_extra['editor']['default-format'] %} selected="selected" {% endif %} >{{ __("Rich Text (WYSIWYG)") }}</option> <option value="RST" {% if config_extra['editor']['default-format'] == 'RST' %} selected="selected" {% endif %} >{{ __("ReStructuredText") }}</option> </select> </div> </div> <div class="table-row"> <div class="table-min-width table-pad-right text-right table-cell align-top"> {{ __("Registration:")|e('html') }} </div> <div class="table-cell full-width"> <div class="multiline_checkbox_container"> <div class="multiline_checkbox"> <input {% if config_extra['board']['enabled'] %}checked="checked"{% endif %} id="board_enabled" type="checkbox" class="large_checkbox" name="{{ form_key_config }}[board][enabled]" /> <label for="board_enabled">{{ __("Enable registration?") }}</label> </div> <div class="multiline_checkbox"> <input {% if config_extra['board']['captcha'] %}checked="checked"{% endif %} id="board_captcha" type="checkbox" class="large_checkbox" name="{{ form_key_config }}[board][captcha]" /> <label for="board_captcha">{{ __("Require a CAPTCHA to register?") }}</label> </div> </div> <fieldset> <legend>{{ __("ReCAPTCHA Settings") }}</legend> <label for="recaptcha_site_key">{{ __("ReCAPTCHA Site Key") }}:</label><br /> <input class="full-width" id="recaptcha_site_key" type="text" name="{{ form_key_config }}[recaptcha][site-key]" value="{{ config_extra['recaptcha']['site-key']|e('html_attr') }}" /> <hr /> <label for="recaptcha_secret_key">{{ __("ReCAPTCHA Secret Key") }}:</label><br /> <input class="full-width" id="recaptcha_secret_key" type="text" name="{{ form_key_config }}[recaptcha][secret-key]" value="{{ config_extra['recaptcha']['secret-key']|e('html_attr') }}" /><br /> </fieldset> </div> </div> <div class="table-row"> <div class="table-min-width table-pad-right text-right table-cell align-top"> {{ __("Account Recovery:")|e('html') }} </div> <div class="table-cell full-width"> <div class="multiline_checkbox_container"> <div class="multiline_checkbox"> <input {% if config_extra['password-reset']['enabled'] %}checked="checked"{% endif %} id="reset_enabled" type="checkbox" class="large_checkbox" name="{{ form_key_config }}[password-reset][enabled]" /> <label for="reset_enabled">{{ __("Enable password reset emails?") }}</label> </div> </div> <label for="reset_token_ttl">{{ __("Token Lifetime") }}:</label> <input id="reset_token_ttl" type="text" placeholder="" name="{{ form_key_config }}[password-reset][ttl]" value="{{ config_extra['password-reset']['ttl']|e('html_attr') }}" /> (seconds) <div class="multiline_checkbox_container"> <div class="multiline_checkbox"> <input {% if config_extra['password-reset']['logout'] %}checked="checked"{% endif %} id="reset_logout" type="checkbox" class="large_checkbox" name="{{ form_key_config }}[password-reset][logout]" /> <label for="reset_logout">{{ __("Logout all other sessions when password is reset?") }}</label> </div> </div> </div> </div> <div class="table-row"> <div class="table-min-width table-pad-right text-right table-cell align-top"> {{ __("Two-Factor Authentication:")|e('html') }} </div> <div class="table-cell full-width"> <!-- Begin 2FA Table --> <div class="table full-width"> <div class="table-row"> <div class="table-min-width table-pad-right text-right table-cell align-top"> <label for="twofactor_label">{{ __("Label") }}:</label> </div> <div class="table-cell full-width"> <input class="full-width" id="twofactor_label" type="text" placeholder="{{ __("e.g. Bridge (Optional)")|e('html_attr') }}" pattern="^[A-Za-z0-9 ]+$" name="{{ form_key_config }}[two-factor][label]" value="{{ config_extra['two-factor']['label']|e('html_attr') }}" /> </div> </div> <div class="table-row"> <div class="table-min-width table-pad-right text-right table-cell align-top"> <label for="twofactor_issuer">{{ __("Issuer") }}:</label> </div> <div class="table-cell full-width"> <input class="full-width" id="twofactor_issuer" type="text" placeholder="e.g. {{ twig_vars['title']|e('html_attr') }} (Optional)" pattern="^[A-Za-z0-9 ]+$" name="{{ form_key_config }}[two-factor][issuer]" value="{{ config_extra['two-factor']['issuer']|e('html_attr') }}" /> </div> </div> <div class="table-row"> <div class="table-min-width table-pad-right text-right table-cell align-top"> <label for="twofactor_digits">{{ __("Digits") }}:</label> </div> <div class="table-cell full-width"> <select id="twofactor_digits" name="{{ form_key_config }}[two-factor][length]" > {% for i in [6, 7, 8] %} <option value="{{ i }}"{# #}{% if config_extra['two-factor']['length'] == i%} selected="selected"{% endif %}{# #}>{{ i }}</option> {% endfor %} </select> {{ __("Warning: Google Authenticator only supports 6 digits.") }} </div> </div> <div class="table-row"> <div class="table-min-width table-pad-right text-right table-cell align-top"> <label for="twofactor_period">{{ __("Period (seconds)") }}:</label> </div> <div class="table-cell full-width"> <input class="full-width" id="twofactor_period" type="text" placeholder="Default: 30" pattern="^[0-9]+$" name="{{ form_key_config }}[two-factor][period]" value="{{ config_extra['two-factor']['period']|e('html_attr') }}" /> </div> </div> </div> <!-- End 2FA Table --> </div> </div> <div class="table-row"> <div class="table-min-width table-pad-right text-right table-cell align-top"> <label for="file_cache"> {{ __("File Cache") }}: </label> </div> <div class="table-cell full-width"> <input id="file_cache" type="text" name="{{ form_key_config }}[file][cache]" value="{{ config_extra['file']['cache']|e('html_attr') }}" /> (seconds) </div> </div> </div>