{% extends 'wizard/slides/common/base.twig' %}

{% block slide_body %}

	<h3>Unrecognised File Scanner Results</h3>
	{% if data.files.has %}
		<div class="indent_slight">
			<p>A total of {{ data.files.count }} file(s) were discovered.</p>
			<ul>
			{% for file in data.files.list %}
				<li><code class="filepath">{{ file }}</code></li>
			{% endfor %}
			</ul>
		</div>
		<p>To have the scanner delete the files listed above, use the confirmation form below.</p>
		<p><strong>Important</strong>: Remember it is not the job of the scanner to determine
			whether you need these files on your website. This is <em>your role</em>.
			We can only show you what's there. If you have doubts, please discuss
			this with your web hosting provider.
		</p>
		<form class="form-horizontal icwp-wizard-form">
			<input name="wizard-step" value="deletefiles" type="hidden" />
			<div class="form-group">
				<label class="col-md-4 control-label" for="DeleteFiles">Delete Detected Files</label>
				<div class="col-md-8">
					<label for="DeleteFiles">
						<input type="checkbox" value="Y" name="DeleteFiles" id="DeleteFiles">
						Check to delete the unrecognised files.
					</label>
					<span id="helpBlock" class="help-block">
						If there are files on this list that you do not want to delete, please go back
						a step in the wizard and add them to your exclusions list.
						<br />For security reasons, the scanner <strong>does not</strong>
						currently support individual selection of files to delete.
					</span>
				</div>
			</div>

			<div class="form-group">
				<div class="col-md-offset-4 col-md-8">
					<button type="submit" class="btn btn-warning">Delete Unrecognised Files</button>
				</div>
			</div>
		</form>

	{% else %}
		<p>There were no files discovered in the scan.</p>
		<p>This could be because there are none, or your exclusions list is ensuring they're ignored.</p>
	{% endif %}
{% endblock %}