Perhaps this idea do not need a special plugin, but should be implemented in WonderCMS as a simple evolution ? : the ability to grant a restricted access to the entire site, via a simple password (or a couple code/password, but I think a simple password should be enough, as WCMS is not intended to work with different users and specific rights).
Here is a simple code that should be integrated on WCMS'index.html :
Code: Select all
<?php
session_start();
if (isset($_SESSION['count']) && ($_SESSION['count'] > 4)) {
header('Location: https://www.wondercms.com/');
} else {
?>
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8" />
<title>Texte</title>
<style>
</style>
</head>
<body>
<?php
$password = 'motdepasse';
if ((isset($_POST['password']) && ($_POST['password'])) != $password) {
if (!isset($_SESSION['count'])) {
$_SESSION['count'] = 0;
} else {
$_SESSION['count']++;
}
?>
<h1>Connexion</h1>
<form name="form" method="post" action="<?php echo $_SERVER['PHP_SELF']; ?>">
<p><label for="password">Password</label> <input type="password" title="Please type password" name="password" /></p>
<p><input type="submit" name="submit" value="Connexion" /></p>
</form>
<?php
} else { ?>
<p>Here is the text.</p>
<?php
}
}
?>
</body>
</html>
Isn't it a good idea ?

Thanks for your attention.
Etienne, France.