[add] azerty layout
This commit is contained in:
parent
9c3d5be2a2
commit
c59702b5c5
4 changed files with 14 additions and 9 deletions
|
@ -49,6 +49,7 @@
|
|||
<div class="row" style="margin-top: 30px;">
|
||||
<p>What's your Keyboard layout?</p>
|
||||
<select type="text" name="keyboardlayout">
|
||||
<option value="azerty">AZERTY</option>
|
||||
<option value="qwerty">QWERTY</option>
|
||||
<option value="qwertz">QWERTZ</option>
|
||||
</select>
|
||||
|
|
|
@ -80,6 +80,10 @@ class Configuration
|
|||
*/
|
||||
public static function evalKeys($keys)
|
||||
{
|
||||
// Return azerty
|
||||
if (strtolower($keys) === 'azerty') {
|
||||
return 'AZERTYUIOPQSDFGHJKLMWXCVBN';
|
||||
}
|
||||
// Return qwertz
|
||||
if (strtolower($keys) === 'qwertz') {
|
||||
return 'QWERTZUIOPASDFGHJKLYXCVBNM';
|
||||
|
|
|
@ -105,7 +105,7 @@ class RequestUtils
|
|||
{
|
||||
if (
|
||||
isset($_POST['keyboardlayout']) &&
|
||||
preg_match("/qwerty|qwertz/", $_POST['keyboardlayout'])
|
||||
preg_match("/azerty|qwerty|qwertz/", $_POST['keyboardlayout'])
|
||||
) {
|
||||
return strtolower($_POST['keyboardlayout']);
|
||||
}
|
||||
|
|
Reference in a new issue