Jump to content

Hardik Joshi

Member
  • Content Count

    52
  • Joined

  • Last visited

  • Days Won

    1

Hardik Joshi last won the day on January 6

Hardik Joshi had the most liked content!

Community Reputation

13 Good

2 Followers

About Hardik Joshi

  • Rank
    Member

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. Hello Community, i have lots of users who registered with us and using our services regularly but they did't verify there email 😞 i wanna create something like the hook, which restrict the whole user dashboard until they have unverified email, once the email verified he will be able to use. is there anyone have any idea regarding this ? Thanks,
  2. Thanks @DennisHermannsen yes there is some issues in `cc_encryption_hash` that's why it is, now it's been fixed. thanks man
  3. Hello Community, it's been while my WHMCS working so smoothly, and after updating to v8.2 am facing some weird issue, when i see my clients product and services the password is not sawing correctly you can see the below screenshot. Please help me with it :)
  4. Hello Team @WGS, I wan to little modify one step checkout order form like some where spaces/line break and for clientx i want to add my websites main header as clientx client-area theme header This is Clientx Header This is my websites Main Header Also i want to add footer also as same my main website 🙂 Thanks, I hope you will help me with this,
  5. Thanks @brian!, i tried with this but it's not working, may be am doing something wrong can you please check once, below code. it's not sawing any error, there are no output i mean not sawing password . <div class="cpanel-package-details"> <em>{$groupname}</em> <h4 style="margin:0;">{$product}</h4> <a href="http://{$domain}" target="_blank">www.{$domain}</a> <h3>cPanel Password: <input type="password" value="{$realpassword}" id="myInput"></h3> <br> <input type="checkbox" onclick="myFunction()"> Show Password </div> <script> function myFunction() { var x = document.getElementById("myInput"); if (x.type === "password") { x.type = "text"; } else { x.type = "password"; } } </script>
  6. Hello Community, I starts Hosting company a year ago and it's really awesome experience but there are few needs in WHMCS, can we add an option in WHMCS products and services details page, Shaw cPanel Password I already added few things like Nameservers, IP and Hostname just need to add one option and it's Shaw you cPanel Password
  7. Thanks @brian! as always, me and my team really need this feature back and you done it 👍🏻
  8. Hey @twhiting9275 I want to customise it little more, can we add location name in Hostname ? like below image you can see IP Location : Rajkot, Gujarat (IN)
  9. Hii @ManagedCloud-Hosting create a file in WHMCS Installation Directory/includes/hook/clientalert.php Past this code and Enjoy 🙂 <?php /* Client area login notifications for WHMCS (works with versions 6-8) Created by whmcsguru Contributions by brian! */ use WHMCS\Database\Capsule; $myver = get_whmcs_version(); $isadmin = $_SESSION['adminid']; $admnotify = FALSE; //change this to true you want to send notifications when admin logged in.. //NOT advisable. this will let your clients know when you're logging into their account if (!empty($isadmin)) { if (!$admnotify) { return; } } function hook_client_login_notify($vars) { $mailsent=FALSE; global $myver; $myver = get_whmcs_version(); if ($myver < 8) { $userid = $vars['userid']; send_login_notify($userid); return; } if ($myver >= 8) { $user = $vars['user']; $userid = $user->id; //a dirty hack to try to work around a couple of things, maybe $acctowner = Capsule::table('tblusers_clients') ->where('auth_user_id', '=', $userid) ->where('owner', '=', 1) ->count(); $numrows = Capsule::table('tblusers_clients') ->where('auth_user_id', '=', $userid) ->count(); //we own our account. We must always notify us directly if ($acctowner > 0) { send_login_notify($userid); return; } //we don't own our account, so, notify the owner, if we only exist once. if ($numrows < 2) { foreach (Capsule::table('tblusers_clients')->WHERE('auth_user_id', '=', $userid)->get() as $userstuff){ $userid = $userstuff->auth_user_id; $clientid = $userstuff->client_id; $owner = $owner; if ($acctowner < 1) { send_login_notify($clientid, $userid); return; } } } return; } } function send_login_notify($myclient, $theuserid="") { global $myver; $ip = $_SERVER['REMOTE_ADDR'] ; $hostname = gethostbyaddr($ip); if ($myver < 8) { $clientinfo = Capsule::table('tblclients')->select('firstname', 'lastname')->WHERE('id', $myclient)->get(); foreach ($clientinfo as $clrow) { $firstname = $clrow->firstname; $lastname = $clrow->lastname; } } if ($myver >= 8) { $clientinfo = Capsule::table('tblusers')->select('first_name', 'last_name')->WHERE('id', $myclient)->get(); foreach ($clientinfo as $clrow) { $firstname = $clrow->first_name; $lastname = $clrow->last_name; } } $command = "sendemail"; $values["customtype"] = "general"; if (empty($theuserid)) { $values["customsubject"] = "Account Login from $hostname"; $values["custommessage"] = "<p>Hello $firstname $lastname,<p>Your account was recently successfully accessed by a remote user. If this was not you, please do contact us immediately<p>IP Address: $ip<br/>Hostname: $hostname<br />"; } elseif ($theuserid > 0) { $moreinfo = Capsule::table('tblusers')->select('first_name', 'last_name', 'email')->WHERE('id', $theuserid)->get(); //greet them foreach ($moreinfo as $userrow) { $ufirst = $userrow->first_name; $ulast = $userrow->last_name; $uemail = $userrow->email; } $values["customsubject"] = "Subaccount Login from $hostname"; $values["custommessage"] = "<p>Hello $firstname $lastname,<p> A subaccount of yours just logged in. Please see the details of the login below <p> Name: $ufirst $ulast Email: $uemail IP Address: $ip Hostname: $hostname<br />"; } $values["id"] = $myclient; $results = localAPI($command, $values); } if ($myver < 8) { add_hook('ClientLogin', 1, 'hook_client_login_notify'); } if ($myver >= 8) { add_hook('UserLogin', 1, 'hook_client_login_notify'); } function get_whmcs_version() { $theversion = Capsule::table('tblconfiguration')->where('setting', '=', 'Version')->value('value'); $retver = substr($theversion, 0,1); return ($retver); }
  10. Yup, Thanks @twhiting9275 Now it's Working Perfect,
  11. Hello @brian! in WHMCS V8.x.x This hook is not working can you please look once. Also can we use different smtp in this hook to send alert email?
  12. is this possible with WHMCS " api " Like This $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, 'https://www.example.com/includes/api.php'); curl_setopt($ch, CURLOPT_POST, 1); curl_setopt($ch, CURLOPT_POSTFIELDS, http_build_query( array( 'action' => 'ResetPassword', // See https://developers.whmcs.com/api/authentication 'username' => 'IDENTIFIER_OR_ADMIN_USERNAME', 'password' => 'SECRET_OR_HASHED_PASSWORD', 'email' => 'john.doe@example.com', 'responsetype' => 'json', ) ) ); curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); $response = curl_exec($ch); curl_close($ch);
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use & Guidelines and understand your posts will initially be pre-moderated