Support the ongoing development of Laravel.io →

4,314 Threads

Categories and sub-categories and how to display the products in each category

Hi Friends "Sorry, my English is poor translation." About the categories and sub-categorie...

0 Likes
4 Replies

Elastic search

Hi, Finally I found forum for Laravel learners. I am struggling with last couple of days for integra...

0 Likes
4 Replies

Accessing the related column data in view

Hi guys. I have two models in my project: Category and Product. Each product belongs to 1 category a...

0 Likes
2 Replies
Solved

Eloquent relations problem

Hi everybody! I have following query in my controller $start = '2014-12-12'; $end = '2014-12-12'; $p...

0 Likes
2 Replies

How to create a relationship that joins on two (multiple) non-standard columns.

I've seen this question asked slightly differently several times in other threads. But the problem I...

0 Likes
0 Replies

Laravel equivalent .try() method in Ruby

Earlier today I asked on the chat room about php/laravel's equivalent of .try() in ruby - http://api...

0 Likes
2 Replies

Before find hook

Hi! I am creating a second project for a company. The first one was written by me in Yii framework....

0 Likes
5 Replies

Query builder vs Eloquent builder relations and `load(relation)` issues

My question is summed up nicely in this bin- This is my first attempt at a 'search builder' function...

0 Likes
1 Replies
posted 10 years ago

Sorting eager loaded results

I'm having this problem with multiple methods in multiple controllers. Here is my method: $original...

0 Likes
5 Replies

Many-to-Many returns NULL

I have no issues writing to my pivot table, but returning associations returns null Schema: $table-...

0 Likes
0 Replies
posted 10 years ago

Model::create() doesnt return a ID

Hey guys, How can i get the ID of my saved model? I dont use save(). I use create(). $page = new...

0 Likes
2 Replies

XML 2 MySQL Solution

Hi everyone! I have been searching for a solution to import XML to a MySQL database without knowing...

0 Likes
1 Replies

Count and Max in a same query

Hi! I'm trying to execute a complex query with Eloquent. So, I have a model "User" which...

0 Likes
7 Replies

Duplicated hasmany relation or not showing at all?!

Alright so I have a ticket with many ticket replies public function show($id){ $ticket = Ticket::fi...

0 Likes
1 Replies
Solved
posted 10 years ago

Eloquent confused about which id column to use when using a join with eager loading

I have the following query that's supposed to eager load data from the 'features' and 'images' table...

0 Likes
1 Replies
Solved
posted 10 years ago

Creating relationship with keys not in integer

I meet a problem when making eloquent. Now I have two tables in my database, say "Users" a...

0 Likes
2 Replies
Solved

Parent item in same table join ?

Hello ! I have a table that contains Pages with columns (ID,Title,Parent_id) page can be root(Parent...

0 Likes
0 Replies

IF statement in query on Laravel 3, possible?

Hi all, For a project running Larvavel 3, I need to modify an existing query using an if statement,...

0 Likes
0 Replies

Eloquent relation with where condition on model attribute

I have two models Student and StudentRevision with Student model having hasMany relation with Studen...

0 Likes
1 Replies

counter for email

Is there a way to count email that has been send to the address of the website

0 Likes
6 Replies

Thanks to our community

Solutions given in the past year. Excluding solutions from thread authors.

Moderators

We'd like to thank these amazing companies for supporting us

Your logo here?

Laravel.io

The Laravel portal for problem solving, knowledge sharing and community building.

© 2025 Laravel.io - All rights reserved.