diff --git a/modules/core/templates/no_metadata.twig b/modules/core/templates/no_metadata.twig new file mode 100644 index 0000000000000000000000000000000000000000..818c08a8ca46d0a222f8f64c87b00f588ecbc23e --- /dev/null +++ b/modules/core/templates/no_metadata.twig @@ -0,0 +1,7 @@ +<p>{{ '{core:no_metadata:config_problem}' | trans }}</p> + +<ul> + <li>{{ '{core:no_metadata:suggestion_user_link}' | trans }}</li> + <li>{{ '{core:no_metadata:suggestion_developer}' | trans }}</li> +</ul> + diff --git a/modules/core/templates/no_state.twig b/modules/core/templates/no_state.twig new file mode 100644 index 0000000000000000000000000000000000000000..9ae61fb5dcbc9316dfab58a2286b69698e6ec2d4 --- /dev/null +++ b/modules/core/templates/no_state.twig @@ -0,0 +1,12 @@ +<h3>{{ '{core:no_state:suggestions}' | trans }}</h3> +<ul> + <li>{{ '{core:no_state:suggestion_goback}' | trans }}</li> + <li>{{ '{core:no_state:suggestion_closebrowser}' | trans }}</li> +</ul> + +<h3>{{ '{core:no_state:causes}' | trans }}</h3> +<ul> + <li>{{ '{core:no_state:cause_backforward}' | trans }}</li> + <li>{{ '{core:no_state:cause_openbrowser}' | trans }}</li> + <li>{{ '{core:no_state:cause_nocookie}' | trans }}</li> +</ul> diff --git a/templates/error.twig b/templates/error.twig new file mode 100644 index 0000000000000000000000000000000000000000..7e226502a9a2034eef1375840513501dfef589f1 --- /dev/null +++ b/templates/error.twig @@ -0,0 +1,69 @@ + +{% set pagetitle = 'Logged out'|trans %} +{% extends "base.twig" %} + +{% block postload %} + <script type="text/javascript"> + new Clipboard('.clipboard-btn'); + </script> +{% endblock %} + +{% block content %} + <h2>{{ dictTitle | trans }}</h2> + {{ dictDescr | trans(parameters) }} + + {# include optional information for error + Some excepltions set 'incluseTemplate' to the name of a template to include. + e.g. "core:no_state.tpl.php". The format is "<module>:<template name>" + #} + {% if includeTemplate %} + {% include(includeTemplate) %} + {% endif %} + + {# TODO: Update class #} + <div class="metadatabox"> + <p>{{ '{errors:report_trackid}' | trans }}</p> + {# TODO: Update class #} + <div class=""> + <pre id="trackid">{{ error.trackId }}</pre> + <button data-clipboard-target="#trackid" id="btntrackid" class="clipboard-bnt pure-button left clipboard-btn"> + <i class="fa fa-copy"></i> + </button> + </div> + </div> + + {# print out exception only if the exception is available #} + {% if showerrors %} + <h2>{{'{errors:debuginfo_header}' | trans}}</h2> + <p>{{'{errors:debuginfo_text}' | trans}}</p> + + {# TODO: Update class #} + <div class="metadatabox"> + <pre>{{ error.exceptionMsg }}</pre> + <pre>{{ error.exceptionTrace }}</pre> + </div> + {% endif %} + + {# Add error report submit section if we have a valid technical contact. 'errorreportaddress' will only be set if + the technical contact email address has been set. #} + {% if errorReportAddress %} + <h2>{{ '{errors:report_header}' | trans }}</h2> + <form action="{{ errorReportAddress }}" method="post"> + <p>{{ '{errors:report_text}' | trans }}</p> + <p>{{ '{errors:report_email}' | trans }} + <input type="email" name="email" value="{{ email }}" /> + </p> + <p> + <textarea class="metadatabox" name="text" rows="6" cols="50">{{ '{errors:report_explain}' | trans }}</textarea> + </p> + </form> + <p> + <input type="hidden" name="reportId" value="{{ error.reportId }}" /> + <button type="submit" name="send" class="btn">{{ '{errors:report_submit}' | trans }}</button> + </p> + {% endif %} + + <h2>{{ '{errors:howto_header}' | trans }}</h2> + <p>{{ '{errors:howto_text}' | trans }}</p> + +{% endblock %} \ No newline at end of file