beracah.kings

beracah.kings

Member Since 3 Years Ago

Experience Points
4,670
Total
Experience

330 experience to go until the next level!

In case you were wondering, you earn Laracasts experience when you:

  • Complete a lesson — 100pts
  • Create a forum thread — 50pts
  • Reply to a thread — 10pts
  • Leave a reply that is liked — 50pts
  • Receive a "Best Reply" award — 500pts
Lessons Completed
13
Lessons
Completed
Best Reply Awards
0
Best Reply
Awards
  • start your engines Created with Sketch.

    Start Your Engines

    Earned once you have completed your first Laracasts lesson.

  • first-thousand Created with Sketch.

    First Thousand

    Earned once you have earned your first 1000 experience points.

  • 1-year Created with Sketch.

    One Year Member

    Earned when you have been with Laracasts for 1 year.

  • 2-years Created with Sketch.

    Two Year Member

    Earned when you have been with Laracasts for 2 years.

  • 3-years Created with Sketch.

    Three Year Member

    Earned when you have been with Laracasts for 3 years.

  • 4-years Created with Sketch.

    Four Year Member

    Earned when you have been with Laracasts for 4 years.

  • 5-years Created with Sketch.

    Five Year Member

    Earned when you have been with Laracasts for 5 years.

  • school-in-session Created with Sketch.

    School In Session

    Earned when at least one Laracasts series has been fully completed.

  • welcome-newcomer Created with Sketch.

    Welcome To The Community

    Earned after your first post on the Laracasts forum.

  • full-time-student Created with Sketch.

    Full Time Learner

    Earned once 100 Laracasts lessons have been completed.

  • pay-it-forward Created with Sketch.

    Pay It Forward

    Earned once you receive your first "Best Reply" award on the Laracasts forum.

  • subscriber Created with Sketch.

    Subscriber

    Earned if you are a paying Laracasts subscriber.

  • lifer Created with Sketch.

    Lifer

    Earned if you have a lifetime subscription to Laracasts.

  • evangelist Created with Sketch.

    Laracasts Evangelist

    Earned if you share a link to Laracasts on social media. Please email [email protected] with your username and post URL to be awarded this badge.

  • chatty-cathy Created with Sketch.

    Chatty Cathy

    Earned once you have achieved 500 forum replies.

  • lara-veteran Created with Sketch.

    Laracasts Veteran

    Earned once your experience points passes 100,000.

  • 10k-strong Created with Sketch.

    Ten Thousand Strong

    Earned once your experience points hits 10,000.

  • lara-master Created with Sketch.

    Laracasts Master

    Earned once 1000 Laracasts lessons have been completed.

  • laracasts-tutor Created with Sketch.

    Laracasts Tutor

    Earned once your "Best Reply" award count is 100 or more.

  • laracasts-sensei Created with Sketch.

    Laracasts Sensei

    Earned once your experience points passes 1 million.

  • top-50 Created with Sketch.

    Top 50

    Earned once your experience points ranks in the top 50 of all Laracasts users.

Level 1
4,670 XP
May
20
1 week ago
Activity icon

Replied to Email Error

yes I had enabled less secure apps. Still I received the error. Issue got sorted after enabling two factor verification and generating an app password

May
19
2 weeks ago
Activity icon

Replied to Email Error

I tried the steps mentioned in this page. Everything is ok now https://medium.com/graymatrix/using-gmail-smtp-server-to-send-email-in-laravel-91c0800f9662

Activity icon

Started a new Conversation Email Error

Im using gmail to send mails through my laravel app. It was working with Godaddy. Now we have shifted the site to a new hosting provider.

Though the credentials are correct. I get the below error msg ailed to authenticate on SMTP server with username "[email protected]" using 3 possible authenticators. Authenticator LOGIN returned Expected response code 235 but got code "535", with message "535-5.7.8 Username and Password not accepted.

May
08
3 weeks ago
Activity icon

Replied to CURL Error

local.ERROR: cURL error 28: Resolving timed out after 10000 milliseconds {"userId":,"exception":"[object] (Requests_Exception(code: 0): cURL error 28: Resolving timed out after 10000 milliseconds at /home/yhpbqlmtkrsl/marvel/vendor/rmccue/requests/library/Requests/Transport/cURL.php:422)

Im using Razorpay (india). Everything was working fine. Suddenly from last week, the error has been appearing continuosly for all users. Godaddy has replied that nothing has been blocked in their end.

Please guide

May
01
1 month ago
Activity icon

Started a new Conversation CURL Error

Hi,

im receiving the below error msg when i try to submit the data to the payment gateway. what could be the reason for this error

Requests_Exception cURL error 28: Resolving timed out after 10000 milliseconds

Feb
20
3 months ago
Activity icon

Started a new Conversation Laravel Or Symfony

I have come across this sentence multiple times 'Symfony is generally for larger projects and Laravel for smaller ones". What are the criteria that makes a project small or big

Feb
18
3 months ago
Activity icon

Replied to User Creation

thank you @willvincent

Feb
17
3 months ago
Activity icon

Replied to User Creation

If the storage engine is InnoDB the transaction is rolled back. However if the storage engine is MyISAM the transaction is commited even before DB::commit is called.

Activity icon

Started a new Conversation User Creation

Im creating a user through the built in laravel methods. I hv added two more parameters inside the register controller create function. Process goes smoothly. However if there is an error, the id is automatically updated in the database but the entry is not inserted in to the table. The id is incremented to the next value.

How to resolve this.

Jan
31
4 months ago
Activity icon

Replied to Sql Injection In Laravel

$example=$example2 
        ->when($value1, function($query, $value1) {
         $query->where('value1', $value1);
        })->when($value2, function($query, $value2) {
         $query->where('value2', $value2);        
        ->paginate(5); 

Im retrieving values into $value1 before passing them. Is this query safe from SQL injection.

Jan
29
4 months ago
Activity icon

Replied to .htaccess

Kindly ignore.

I have the changed the code, its now working

RewriteCond %{HTTPS} off
RewriteRule .* https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]
RewriteCond %{HTTP_HOST} !^www\. [NC]
RewriteRule .* https://www.%{HTTP_HOST}%{REQUEST_URI} [L,R=301]


Activity icon

Started a new Conversation .htaccess

Im able to redirect all traffice to https if the the url is not prefixed with www. However when I type www.example.com it doesnt redirect to https://www.example.com

<IfModule mod_rewrite.c>
    <IfModule mod_negotiation.c>
        Options -MultiViews -Indexes
    </IfModule>

    RewriteEngine On
    # Added to Force HTTPS    
    RewriteCond %{HTTP_HOST} ^example\.com [NC]    
    RewriteCond %{SERVER_PORT} 80
    RewriteRule ^(.*)$ https://www.example.com/ [R,L]


    # Handle Authorization Header
    RewriteCond %{HTTP:Authorization} .
    RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]

    # Redirect Trailing Slashes If Not A Folder...
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteCond %{REQUEST_URI} (.+)/$
    RewriteRule ^ %1 [L,R=301]

    # Handle Front Controller...
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteRule ^ /index.php [L]    
    
    
</IfModule>

Jan
20
4 months ago
Activity icon

Replied to File Storage

Thank you jlrdw. The images are of members, im saving them with random generated number stored in the db. Is this an ok practice.

Activity icon

Replied to File Storage

I created a seperate disk under

      'my_files' => [
            'driver' => 'local',
            'root'   => '/home/domain/public_html'. '/myfiles',
        ],

Im able to to view /store images inside the myfiles directory. However is it safe to follow this procedure since laravel recommends to use symbolic link. I validate and allow .jpg/png files of the particular user to upload in the myfiles directory

Jan
19
4 months ago
Activity icon

Replied to Sql Injection In Laravel

Thank you. Entire code is written with eloquent without any raw statements.

Activity icon

Started a new Conversation File Storage

Im hosting laravel in a shared server enviroment. public folder is under public_html and other files are in seperate folder.

Im unable to upload files to the public folder which I want to display. Is there any workaround to resolve this I get "League\Flysystem\Exception Impossible to create the root directory"

Jan
17
4 months ago
Activity icon

Started a new Conversation Sql Injection In Laravel

I m using eloquent for updating data. Is there any possibility of sql injection, if the form data/querystring are not sanitized.

Jan
16
4 months ago
Activity icon

Replied to Laravel Notifications

Notifications dont add a model. The count is calculated from User through eloquent. Is it possible to get count for unreadnotifications of a specific type

Jan
15
4 months ago
Activity icon

Started a new Conversation Laravel Notifications

Im fetching unread notifications in my blade file. However the count for the unread notifications is of entire table and not of particular user. Should I have to add any relationship in User model.

Jan
13
4 months ago
Activity icon

Replied to Concurrent Connections In Pusher

thank you songhua and fylzero. @ Songhua, Pusher team has replied that beyond the connection limit, an error message will be sent from pusher server and no messages will be kept in queue.

@fylzero will definetely check and revert back

Activity icon

Started a new Conversation Concurrent Connections In Pusher

Currently my application is using sandbox plan in pusher. It limits to 100 concurrent connections. My question is if the number of concurrent users increase, will it block the 101st connection or will the messages be sent on a queue.

Jan
05
4 months ago
Activity icon

Started a new Conversation Notification Advice

I hv a client requirement for my matrimony matching website. If a member A visits a profile of member B, the corresponding member B must get notified through a toast message in his page if he is logged in. A badge should display the number of people visited the page of member B. if member B visits his visited members page, the badge should disappeared. Can anybody guide on this. (Similiar to how gmail unread mails are displayed)

Jan
03
4 months ago
Activity icon

Started a new Conversation React - Laravel

Im having a pagination table with Laravel - Ajax - response is html page from ajax. Im planning to change it Laravel - React. Will the json response be faster than the htmlresponse from ajax.

Dec
20
5 months ago
Activity icon

Replied to Date Validation

@nakov thanks, never saw that one. @petrit thanks, will check and comeback

Activity icon

Replied to Date Validation


 protected function validator(array $data)
    {
            return Validator::make($data, [
                'email' => ['required', 'email', 'max:255','unique:partners'],
                'mobile' => ['required', 'min:10', 'max:10','unique:partners'],        

            ], [
                'email.required' => 'Email is required.',
                'email.email' => 'Email needs to have a valid format.',
                'email.unique' => 'Email is already registered.',
                'mobile.required' => 'Mobile Number is required.',                
                'mobile.min' => 'Mobile Number must be at least 10 characters',
                'mobile.max' => 'Mobile Number must be at least 10 characters.',
                'mobile.unique' => 'Mobile Number is already registered.',
         
           ]);
    }

This one worked for me. However numeric and min /max doesnt work when used together.

Activity icon

Replied to Date Validation

@nakov thanks for the reply. @himanshurajvanshi thank you.

Im getting the dates in the register controller. how to send error message in the register controller. how to pass custom error msgs in the validator function

Activity icon

Started a new Conversation Date Validation

im collecting date in the form of seperate select option for day, month and year. Im concatanating before updating in database. How to validate the date and send error message if any one of the select option is null

Dec
13
5 months ago
Activity icon

Awarded Best Reply on Pagination

This answer worked for me

{{ $partnerprofile->appends(request()->except('page'))->links() }}

Im appending the querystring into the url . Now its working

Activity icon

Replied to Pagination

do we have to sanitize the input, im using eloquent for data retrieval

Activity icon

Replied to Pagination

This answer worked for me

{{ $partnerprofile->appends(request()->except('page'))->links() }}

Im appending the querystring into the url . Now its working

Activity icon

Replied to Pagination

@sinnbeck if the values are in the query string, then pagination doesnt work. Only if the values are set inside the controller action then pagination works.

Activity icon

Replied to Pagination

        $gender = $request->input('gender');
        $mothertongue  = $request->input('mothertongue');
        $maritalstatus  = $request->input('maritalstatus');
        $caste  = $request->input('caste');
        $denomination  = $request->input('denomination');


        $partnerprofile2=new \App\partnerprofile;

        $partnerprofile=$partnerprofile2 
        ->when($gender, function($query, $gender) {
         $query->where('gender', $gender);
        })->when($mothertongue, function($query, $mothertongue) {
            $query->where('mothertongue', $mothertongue);
        })->when($maritalstatus, function($query, $maritalstatus) {
            $query->where('maritalstatus', $maritalstatus);
        })->when($caste, function($query, $caste) {
            $query->where('caste', $caste);
        })->when($denomination, function($query, $denomination) {
            $query->where('denomination', $denomination);
        })            
        ->paginate(10);   
        return view('search.response')->with(['partnerprofile'=>$partnerprofile]);


Activity icon

Replied to Pagination

thank you sinnbeck. if i pass values through querystring, only the first page display displays correctly, the second pagination link fetches all the data. What could be wrong.

Activity icon

Replied to Pagination

im collecting data from a form and then submitting to page, after some updates, the data is sent back. i m submitting 10 fields, so will that be odd to pass the parameters in get. can it be done through redirect

Activity icon

Replied to Pagination

im using reqular forms.

Activity icon

Started a new Conversation Pagination

im posting values to a controller function and getting results with paginate. pagination doesnt work with post request. how to resolve.

Activity icon

Replied to Multiple Where

sorry @sinnbeck i posted before refreshing the page. thank you

Activity icon

Replied to Multiple Where

@sinnbeck

could you please explain. If $a exists, then query will include $a , similiar for $b.

Activity icon

Replied to Multiple Where

i want the where condition to be appended to query when some values exists

Activity icon

Started a new Conversation Multiple Where

is it possible to use multiple where conditions in a query based on conditions.

Dec
10
5 months ago
Activity icon

Replied to Multiple Tables

@jlrdw how to handle multiple table inserts. suppose i update 4 tables, all r linked by a common reference key. 1and 2 table get updated 3 table doesnt get updated due to some error.

Dec
09
5 months ago
Activity icon

Replied to Multiple Tables

thank you tray2

Activity icon

Replied to Multiple Tables

thank you nakov. if concurrent users are creating new logins seperately, if any one of them fail, then how auto increment will work. will there be any blank values in the table

Activity icon

Started a new Conversation Multiple Tables

im updating multiple tables inside a controller function. is there a way to rollback the insert if either of the table insertion fails.

Dec
05
5 months ago
Activity icon

Replied to Data Tables

is it possible to get similiar output in laravel like yajra datatables( reduced server overhead) .

Dec
01
6 months ago
Activity icon

Replied to Data Tables

thank you jlrdw. my requirement is to display the search results in the same page. When the options are changed, the page should publish the results again with updated results.

Activity icon

Started a new Conversation Data Tables

I want to display the results in the same page as the query. How to proceed with yajra tables. guidance please