- md5
- a57d598c98dcdaeee32e39bd0e9c491d
- sha1
- 9f9b11f89a8d96e8b7958bbcfe7796d465bf7250
- sha256
- 63e5bc3d9ac761111b019fdd466896224597f6b95c9e8fed307f2aba0c81c5c6
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124
<?php
/**
* @package Joomla.Plugin
* @subpackage Twofactorauth.totp.tmpl
*
* @copyright Copyright (C) 2005 - 2020 Open Source Matters, Inc. All rights reserved.
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
defined('_JEXEC') or die;
use Joomla\CMS\HTML\HTMLHelper;
use Joomla\CMS\Factory;
HTMLHelper::_('script', 'plg_twofactorauth_totp/qrcode.min.js', array('version' => 'auto', 'relative' => true));
$js = "
(function(document)
{
document.addEventListener('DOMContentLoaded', function()
{
var qr = qrcode(0, 'H');
qr.addData('" . $url . "');
qr.make();
document.getElementById('totp-qrcode').innerHTML = qr.createImgTag(4);
});
})(document);
";
Factory::getDocument()->addScriptDeclaration($js);
?>
<input type="hidden" name="jform[twofactor][totp][key]" value="<?php echo $secret ?>" />
<div class="well">
<?php echo JText::_('PLG_TWOFACTORAUTH_TOTP_INTRO') ?>
</div>
<fieldset>
<legend>
<?php echo JText::_('PLG_TWOFACTORAUTH_TOTP_STEP1_HEAD') ?>
</legend>
<p>
<?php echo JText::_('PLG_TWOFACTORAUTH_TOTP_STEP1_TEXT') ?>
</p>
<ul>
<li>
<a href="<?php echo JText::_('PLG_TWOFACTORAUTH_TOTP_STEP1_ITEM1_LINK') ?>" target="_blank" rel="noopener noreferrer">
<?php echo JText::_('PLG_TWOFACTORAUTH_TOTP_STEP1_ITEM1') ?>
</a>
</li>
<li>
<a href="<?php echo JText::_('PLG_TWOFACTORAUTH_TOTP_STEP1_ITEM2_LINK') ?>" target="_blank" rel="noopener noreferrer">
<?php echo JText::_('PLG_TWOFACTORAUTH_TOTP_STEP1_ITEM2') ?>
</a>
</li>
</ul>
<div class="alert">
<?php echo JText::_('PLG_TWOFACTORAUTH_TOTP_STEP1_WARN') ?>
</div>
</fieldset>
<fieldset>
<legend>
<?php echo JText::_('PLG_TWOFACTORAUTH_TOTP_STEP2_HEAD') ?>
</legend>
<div class="span6">
<p>
<?php echo JText::_('PLG_TWOFACTORAUTH_TOTP_STEP2_TEXT') ?>
</p>
<table class="table table-striped">
<tr>
<td>
<?php echo JText::_('PLG_TWOFACTORAUTH_TOTP_STEP2_ACCOUNT') ?>
</td>
<td>
<?php echo $username ?>@<?php echo $hostname ?>
</td>
</tr>
<tr>
<td>
<?php echo JText::_('PLG_TWOFACTORAUTH_TOTP_STEP2_KEY') ?>
</td>
<td>
<?php echo $secret ?>
</td>
</tr>
</table>
</div>
<div class="span6">
<p>
<?php echo JText::_('PLG_TWOFACTORAUTH_TOTP_STEP2_ALTTEXT') ?>
<br />
<div id="totp-qrcode"></div>
</p>
</div>
<div class="clearfix"></div>
<div class="alert alert-info">
<?php echo JText::_('PLG_TWOFACTORAUTH_TOTP_STEP2_RESET') ?>
</div>
</fieldset>
<?php if ($new_totp): ?>
<fieldset>
<legend>
<?php echo JText::_('PLG_TWOFACTORAUTH_TOTP_STEP3_HEAD') ?>
</legend>
<p>
<?php echo JText::_('PLG_TWOFACTORAUTH_TOTP_STEP3_TEXT') ?>
</p>
<div class="control-group">
<label class="control-label" for="totpsecuritycode">
<?php echo JText::_('PLG_TWOFACTORAUTH_TOTP_STEP3_SECURITYCODE') ?>
</label>
<div class="controls">
<input type="text" class="input-small" name="jform[twofactor][totp][securitycode]" id="totpsecuritycode" autocomplete="0">
</div>
</div>
</fieldset>
<?php endif; ?>
The same content is in 30 releases, Joomla 3.9.15-rc to 3.10.0-alpha1. See them all, or every version of this file.