Cyber Monday! Get 25% off for as long as you keep your subscription. New subscribers only.

doncho85

doncho85

Member Since 4 Months Ago

Experience Points
1,050
Total
Experience

3,950 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
4
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
1,050 XP
Nov
18
1 week ago
Activity icon

Replied to Point Field In Mysql

   protected $fillable = [
        'name', 'email', 'password','tagline','about','username','available_to_hire','formatted_address'
    ];

    protected $spatialFields = [
        'location',
        
    ];

Activity icon

Replied to Permission Denied For A .sh Script In Docker

bash doesnt make any difference

Activity icon

Replied to Point Field In Mysql

Hi there,

Yes I've tried but there is no difference

Activity icon

Started a new Conversation Point Field In Mysql

Hi there I am using Laravel and i define a POINT field for lognitude and latitude I am using a package grimzy/laravel-mysql-spatial package but when i update the field is giving me 'null'

this is my controller

 public function updateProfile(Request $request)
    {
        $user = auth()->user();

        $this->validate($request,[
            'tagline'=>['required'],
            'name'=>['required'],
            'about'=>['required','string','min:20'],
            'formatted_address' => ['required'],
            'location.latitude' => ['required','numeric','min:-90','max:90'],
            'location.longitude' => ['required','numeric','min:-180','max:180'],
          ]);

          $location = new Point($request->location['latitude'],$request->location['longitude']);
          $user->update([
              'name' => $request->name,
              'formatted_address' => $request->formatted_address,
              'location' => $location,
              'available_to_hire' => $request->available_to_hire,
              'about' => $request->about,
              'tagline' => $request->tagline,

          ]);

          return new UserResource($user);

    }

Can you please help me ?

Activity icon

Replied to Permission Denied For A .sh Script In Docker

Yes it is a bash script I will try and let you know

Activity icon

Started a new Conversation Permission Denied For A .sh Script In Docker

Hi Everyone,

I am working on MAC OS and I am trying to run a script from my app container but I am ending up with persmission denied after I run compose-build up.


This is is the line :
CMD ./start_script.sh

If anyone can give me any help regrading this I very thankfull.

Thank you very much in advance.

Oct
24
1 month ago
Activity icon

Started a new Conversation Docker Build Error

This is my docker file and im trying to build the container with this command

docker build -t myphpcontainerwithmysqli . and I am facing this error

Invalid signal: SIGWINCH

dockerfile

FROM php:7.3-apache
RUN docker-php-ext-install mysqli
COPY index.php /var/www/html/
Oct
23
1 month ago
Activity icon

Replied to What Is The Best Package For Shopping Cart?

Hi there,

Check this package its very easy to use and have good documentation

https://packagist.org/packages/bumbummen99/shoppingcart

Sep
24
2 months ago
Activity icon

Replied to Forget My Password

did you setup mailtrash?

Sep
07
2 months ago
Activity icon

Replied to Delete Data

try to pass the id in your controller

public function destroy($id)
{
    $category->delete();
    return redirect()->route('categories.index');
}
}
Aug
26
3 months ago
Activity icon

Replied to Vue-router Is Not Working On Xampp

without php artisan serve its not going to work

Activity icon

Replied to Ajax Image Loading From Databse In Laravel

@michaloravec thanks for your help bro it si working basically with this code

    public function ViewPicture($id){
           
        $comment = DB::table('comments')->where('id',$id)->first();

        $picture = asset($comment->image);

        return response::json([
              'image'=> $picture

        ]);
      }
Activity icon

Started a new Conversation Ajax Image Loading From Databse In Laravel

Hi Guys i had a small issue loading a comment picture in modal. I can load any information from the table but not the picture. Any help will be appreciate

This is my blade

<div class="modal fade" id="exampleModal" tabindex="-1" role="dialog" aria-labelledby="exampleModalLabel" aria-hidden="true">
  <div class="modal-dialog modal-dialog-centered" role="document">
    <div class="modal-content">
      <div class="modal-header">
        <h5 class="modal-title" id="exampleModalLabel">Modal title</h5>
        <button type="button" class="close" data-dismiss="modal" aria-label="Close">
          <span aria-hidden="true">&times;</span>
        </button>
      </div>
      <div class="modal-body">
      <img id="pimage" src="">
 
      </div>
      <div class="modal-footer">
      
      
      </div>
    </div>
  </div>
</div>
<script type="text/javascript">
    function viewpicture(id){
        $.ajax({
         url: "{{ url('/view/picture/') }}/"+id, 
         type: "GET",
         dataType:"json",
         success:function(data){
          
        $('#pimage').attr('src', data.image);
     
     }  
        })
    }

</script>

My controller

    public function ViewPicture($id){
           
        $picture = DB::table('comments')->where('id',$id)->first();

        return response::json($picture);
      }

My route

Route::get('/view/picture/{id}','[email protected]'); 

This is how im saving the pictures in the database

  $comment_image_name = hexdec(uniqid()).'.'.$comment_image->getClientOriginalExtension();
            Image::make($comment_image)->resize(300,300)->save('img/'. $comment_image_name);
            $image = 'img/'.$comment_image_name; 
Aug
20
3 months ago
Activity icon

Replied to Get Request With Ajax

finally works !!!! thanks

Aug
19
3 months ago
Activity icon

Replied to Get Request With Ajax

yes i catch your point im using data.product.name i will check tomorrow from my work place and let yog know . Thanks

Activity icon

Replied to Get Request With Ajax

yes sure

Activity icon

Replied to Get Request With Ajax

i will try this

Activity icon

Replied to Get Request With Ajax

yes i was doing exactly the same but its not working and thats why i decided to test with alerts but nothing is happening basically....

Activity icon

Started a new Conversation Get Request With Ajax

Hello guys,

I am trying to make a get request categories table with ajax and pass the data to a modal. I test my route everything is fine its working but for some reason i cannot fetch any data with ajax here is my code:

this is my route


Route::get('edit/category/{id}','[email protected]');

my controller

 public function Edit($id){
          $product = DB::table('categories')->where('id',$id)->first();

         

          return response::json($product);

   
        


      }


my button

<button  data-id="{{$row->id}}" class="addcart" ><i class="fa fa-pencil-square-o" aria-hidden="true"></i></button>


my script


$(document).ready(function(){
     $('.addcart').on('click', function(){
        var id = $(this).data('id');
        if (id) {
            $.ajax({
                url: " {{ url('edit/category/') }}/"+id,
                type:"GET",
                dataType:"json",
                success:function(data){
                   alert('yes');
 
                },
            });
        }else{
            alert('danger');
        }
     });
   });

I check the id with alert op up amnd the id is coming but when test the success or error doesnt showing me nothing . Any help will be appreciated. Thank you very much in advance

Aug
06
3 months ago
Activity icon

Replied to Uploading Image To Folder And Saving Path To Database On A Product Form

@babara are you using Image intervention package ?

Activity icon

Replied to Which Is The Best Practice For User/admin Database Table ?

just create additional field is_admin and create middleware for example 0 will be the user and 1 will be admin

Jul
31
3 months ago
Activity icon

Replied to Vue SPA With Laravel Authentication

Hi there,

Basically you need to install Vue into the laravel environment and like Jeffrey said Vue will be your front end and laravel will be your backend but you need to access backend by API routes and the best solution for that for me was using axios.

Jul
29
4 months ago
Activity icon

Replied to How To Prevent Users To Go To My Login.blade.php After Authentication

thats it simple and nice thanks a lot

Activity icon

Replied to How To Prevent Users To Go To My Login.blade.php After Authentication

I just simply want if they hit login route and they are already logged just to divert them home page and thats all

Activity icon

Replied to How To Prevent Users To Go To My Login.blade.php After Authentication

Hi there,

I make the login form as a welcome page so for example i want them to go to the home page if they are already authenticated.

Thank you very much in advance

Activity icon

Replied to How To Prevent Users To Go To My Login.blade.php After Authentication

This is my code from web.php

Route::get('/', function () { return view('auth.login'); });

//Auth::routes();

Auth::routes([ 'reset' => false, 'verify' => false, 'register' => false, ]);

Jul
28
4 months ago
Activity icon

Replied to How To Prevent Users To Go To My Login.blade.php After Authentication

HI guys ,

Thank you for your prompt response

Basicaly i didnt customize the login I am just using the ldap auth bcz this is ticketing system within the organization.

Activity icon

Started a new Conversation How To Prevent Users To Go To My Login.blade.php After Authentication

Hello guys,

I am building a ticketing system and i just realized that after user is login and hit the /login route again is going to the login.blade.php . Can anyone help me to prevent this please ?