Skip to content

Group by query in in laravel 5.3

I have fired this query: but I got the following error: PDOException in Connection.php line 332: SQLSTATE[42000]: Syntax error or access violation 1055 ‘baseproject_new.articles.user_id’ isn’t in GROUP BY When run the query in mysql I got the result, but when I run the page I got the error. …

Groups Annotations don’t works

Symfony 3.1.7 + FOSRestBundle latest version Then in my Article entity I added this annotation @Groups({“article”}) with the right use statement. Whit default serializer I get : Whit JMS serializer (bundle) I get : (I have two articles in db) it seems like the “article” group is not re…

How to recursively iterate object?

I have instance of this class, which contains an array of several instances of this class. And each of which can contain instances of this class, etc. This class implements the tree model. I want get all objects model as array structure for JSON representation in future. For that I need recursive iterate all …

change option value based on other dropdown PHP

I have 2 simple dropdown list that if city dropdown selected have value “Balikpapan” its display specific option on service dropdown then if not its display other option : here’s my function code : …