Skip to content

Tag: laravel

hasManyThrough – Laravel 5.8

I have database table structure like : ClassRoom id (int) PK name (varchar) ClassTeacherCourse id (int) PK id_classroom (int) FK id_teacher (int) FK id_course (int) FK Course id (int) PK course_name (varchar) Teacher id (int) PK teacher_name (varchar) So far I have code just to call ClassRoom table & Clas…

Laravel I can’t retrieve requester data using with

I am using this package https://github.com/renoki-co/befriended My issue is trying to get all my friends posts with my post including user’s data, but the problem is the requester data is null. Response As you can see the first object in the array dosen’t include the user data. So what should i do…

how to extract key and value from json content?

what I have tried is this. Can anyone help me in extracting keys and values like notificationType,bounceType,timestamp etc; It would be great help for me if anyone help me achieving this. Thank you. Answer json_decode decode a string converting it in php data structures: array or object. Check docs for json_d…