Ubuntu Server add new user

Add a new user to existing Ubuntu Server

Login with sudo-user, then:

      1.  sudo adduser <UserName>
      2. Enter password as stated in command line

Make user sudo-user

      1. sudo adduser <UserName> sudo
      2. To verify type id <UserName>. To the left under „user groups“ it should state „sudo

Source: https://www.cyberciti.biz/faq/how-to-create-a-sudo-user-on-ubuntu-linux-server/

Allow user to login via ssh

      1. Open the ssh config file using vim:
        vim /etc/ssh/sshd_config
      2. Scroll to button until you find AllowUsers
      3. Add username, separate multiple usernames by space:
        AllowUsers user1 user2 user3
      4. Reload ssh:
        service sshd restart

Source: https://kifarunix.com/allow-deny-specific-users-to-login-via-ssh-on-ubuntu-18-04/

UTF8 Daten (Arabisch, Hebräisch, Griechisch etc.) in eine MySQL Datenbank eingeben und auslesen

you must set charset in first connect with mysql by this query:

SET CHARACTER SET utf8

for example in mysqli functions

$MySQL_Handle = mysqli_connect(HOSTNAME,DATABASE_USERNAME,DATABASE_PASSWORD,DATABASE_NAME) 
or die ( mysqli_error($MySQL_Handle) ); 

$sSQL= 'SET CHARACTER SET utf8'; 

mysqli_query($MySQL_Handle,$sSQL) 
or die ('Can\'t charset in DataBase'); 

and PDO sample :

$dbh = new PDO('mysql:host=localhost;dbname=' . $DB_NAME, $DB_USER,
$DB_PASS, array(PDO::MYSQL_ATTR_INIT_COMMAND => "SET NAMES 'UTF8'"));
$dbh->exec("SET CHARACTER SET UTF8");

this action need before insert and before select.