You could build up your query dynamically and add conditions as you go through your if statements.
$query = new Search;
if (condition) $query->whereCondition(condition);
$results = $query->get();
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community