Slide 1
Most trusted JOB oriented professional program
DevOps Certified Professional (DCP)

Take your first step into the world of DevOps with this course, which will help you to learn about the methodologies and tools used to develop, deploy, and operate high-quality software.

Slide 2
DevOps to DevSecOps – Learn the evolution
DevSecOps Certified Professional (DSOCP)

Learn to automate security into a fast-paced DevOps environment using various open-source tools and scripts.

Slide 2
Get certified in the new tech skill to rule the industry
Site Reliability Engineering (SRE) Certified Professional

A method of measuring and achieving reliability through engineering and operations work – developed by Google to manage services.

Slide 2
Master the art of DevOps
Master in DevOps Engineering (MDE)

Get enrolled for the most advanced and only course in the WORLD which can make you an expert and proficient Architect in DevOps, DevSecOps and Site Reliability Engineering (SRE) principles together.

Slide 2
Gain expertise and certified yourself
Azure DevOps Solutions Expert

Learn about the DevOps services available on Azure and how you can use them to make your workflow more efficient.

Slide 3
Learn and get certified
AWS Certified DevOps Professional

Learn about the DevOps services offered by AWS and how you can use them to make your workflow more efficient.

previous arrow
next arrow

How to enable Google reCaptcha with Laravel?

Spread the Knowledge

Step 1 – First go to https://www.google.com/recaptcha/intro/v3.html then click on Admin console

Step 2 – Genereate new recaptcha (click on + button to create)

  1. Type label name
  2. Select ReCaptcha v2 ► select “I’m not a robot” Checkbox
  3. Domains (localhost) or your website address eg www.example.com
  4. Accept the ReCaptcha term of service ( tick checkbox)
  5. send alerts to owners (tick checkbox already) ► click on submit button

Step 3 – after that you will see site key – like this
(6LdtjbYUAAAAANm-tqllPU_O-rHyZ-0HwR0COkYk)

Step 4 – and secret key like this (6LdtjbYUAAAAABDNEWDL2EgBN2pq76AdgHQoLx77)

Step 5 – copy both keys in notepad.

Step 6 -Put below javascript code in resources/views/layouts/app.blade.php

Step 7 – and put below code in your form area above submit button

@if(errors->has(‘g-recaptcha-response’))

{{$errors->first(‘g-captcha-response’)}}

@endif

Step 8 – open any terminal like gitbash or PowerShell and type this command (composer require google/recaptcha ‘~1.1’ press enter
► then run command php artisan make:rule Captcha (press enter)
► then open app/Rules/Captcha.php and add below lines

use ReCaptcha\ReCaptcha;

► and add below codes to Captcha.php

public function passes($attribute, $value)
{
$recaptcha = new ReCaptcha(env(‘CAPTCHA_SECRET’));
$response = $recaptcha->verify($value, $_SERVER[‘REMOTE_ADDR’]);
return $response->isSuccess();
}
—–
public function message()
{
return ‘Please complete the recaptcha to submit the form’;
}

Step 9 – and add below lines to app/Http/User/JobController.php

use App\Rules\Captcha;

Step 10 – and add under validator ‘g-captcha-response’ => new Captcha(),

If you have any query then comment us we will solve your issue and give you also some awesome steps and tricks to solve it. Please follow us for future reference on other topics like PHP, Laravel and other languages.

For More reference Please check this out :

Chandan Kumar
Follow Me: