$drop_url = DI::args()->getQueryString();
return Renderer::replaceMacros(Renderer::getMarkupTemplate('confirm.tpl'), [
- '$method' => 'post',
- '$message' => DI::l10n()->t('Do you really want to delete this photo album and all its photos?'),
- '$confirm' => DI::l10n()->t('Delete Album'),
- '$confirm_url' => $drop_url,
- '$confirm_name' => 'dropalbum',
+ '$l10n' => [
+ 'message' => DI::l10n()->t('Do you really want to delete this photo album and all its photos?'),
+ 'confirm' => DI::l10n()->t('Delete Album'),
+ 'cancel' => DI::l10n()->t('Cancel'),
+ ],
+ '$method' => 'post',
+ '$confirm_url' => $drop_url,
+ '$confirm_name' => 'dropalbum',
'$confirm_value' => 'dropalbum',
- '$cancel' => DI::l10n()->t('Cancel'),
]);
}
$drop_url = DI::args()->getQueryString();
return Renderer::replaceMacros(Renderer::getMarkupTemplate('confirm.tpl'), [
- '$method' => 'post',
- '$message' => DI::l10n()->t('Do you really want to delete this photo?'),
- '$confirm' => DI::l10n()->t('Delete Photo'),
- '$confirm_url' => $drop_url,
- '$confirm_name' => 'delete',
+ '$l10n' => [
+ 'message' => DI::l10n()->t('Do you really want to delete this photo?'),
+ 'confirm' => DI::l10n()->t('Delete Photo'),
+ 'cancel' => DI::l10n()->t('Cancel'),
+ ],
+ '$method' => 'post',
+ '$confirm_url' => $drop_url,
+ '$confirm_name' => 'delete',
'$confirm_value' => 'delete',
- '$cancel' => DI::l10n()->t('Cancel'),
]);
}
DI::page()['aside'] = '';
return Renderer::replaceMacros(Renderer::getMarkupTemplate('contact_drop_confirm.tpl'), [
- '$header' => DI::l10n()->t('Drop contact'),
+ '$l10n' => [
+ 'header' => DI::l10n()->t('Drop contact'),
+ 'message' => DI::l10n()->t('Do you really want to delete this contact?'),
+ 'confirm' => DI::l10n()->t('Yes'),
+ 'cancel' => DI::l10n()->t('Cancel'),
+ ],
'$contact' => self::getContactTemplateVars($orig_record),
'$method' => 'get',
- '$message' => DI::l10n()->t('Do you really want to delete this contact?'),
- '$confirm' => DI::l10n()->t('Yes'),
'$confirm_url' => DI::args()->getCommand(),
'$confirm_name' => 't',
'$confirm_value' => BaseModule::getFormSecurityToken('contact_action'),
- '$cancel' => DI::l10n()->t('Cancel'),
]);
}
// Now check how the user responded to the confirmation query
<center>
<form action="{{$confirm_url}}" id="confirm-form" method="{{$method}}">
- <h3 id="confirm-message">{{$message}}</h3>
+ <h3 id="confirm-message">{{$l10n.message}}</h3>
- <button class="confirm-button" id="confirm-submit-button" type="submit" name="{{$confirm_name}}" value="{{$confirm_value}}">{{$confirm}}</button>
- <button class="confirm-button" id="confirm-cancel-button" type="submit" name="canceled" value="{{$cancel}}">{{$cancel}}</button>
+ <button class="confirm-button" id="confirm-submit-button" type="submit" name="{{$confirm_name}}" value="{{$confirm_value}}">{{$l10n.confirm}}</button>
+ <button class="confirm-button" id="confirm-cancel-button" type="submit" name="canceled" value="{{$l10n.cancel}}">{{$l10n.cancel}}</button>
</form>
</center>
-<h1>{{$header}}</h1>\r
-\r
-{{include file="contact_template.tpl" no_contacts_checkbox=True}}\r
-\r
-{{include file="confirm.tpl"}}\r
-\r
-\r
+<h1>{{$l10n.header}}</h1>
+
+{{include file="contact_template.tpl" no_contacts_checkbox=True}}
+
+{{include file="confirm.tpl"}}
+
+
<div class="clear"></div>
\ No newline at end of file
<form action="{{$confirm_url}}" id="confirm-form" method="{{$method}}" class="generic-page-wrapper">
- <div id="confirm-message">{{$message}}</div>
+ <div id="confirm-message">{{$l10n.message}}</div>
<div class="form-group pull-right settings-submit-wrapper">
- <button type="submit" name="{{$confirm_name}}" id="confirm-submit-button" class="btn btn-primary confirm-button" value="{{$confirm_value}}">{{$confirm}}</button>
- <button type="submit" name="canceled" value="{{$cancel}} id="confirm-cancel-button" class="btn confirm-button" data-dismiss="modal">{{$cancel}}</button>
+ <button type="submit" name="{{$confirm_name}}" id="confirm-submit-button" class="btn btn-primary confirm-button" value="{{$confirm_value}}">{{$l10n.confirm}}</button>
+ <button type="submit" name="canceled" value="{{$l10n.cancel}}" id="confirm-cancel-button" class="btn confirm-button" data-dismiss="modal">{{$l10n.cancel}}</button>
</div>
</form>
-<div id="contact-drop-confirm">\r
- <h2 class="heading">{{$header}}</h2>\r
-\r
- {{include file="contact_template.tpl" no_contacts_checkbox=True}}\r
-\r
- {{include file="confirm.tpl"}}\r
-\r
- <div class="clear"></div>\r
-</div>\r
+<div id="contact-drop-confirm">
+ <h2 class="heading">{{$l10n.header}}</h2>
+
+ {{include file="contact_template.tpl" no_contacts_checkbox=True}}
+
+ {{include file="confirm.tpl"}}
+
+ <div class="clear"></div>
+</div>