Skip to content

Tag: php

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 …

CSV to HTML Table using php

I am trying to take data from my CSV file and use php to display it in an html table, sorted by customer last name. I have tried a couple things and it doesn’t seem to be working. The output I got is: Right now the format is last, first,address,city,district,postal code How would i import this to an htm…

mysql query return boolean but I expect to return id

This is my query: What is wrong in this query? I’m expecting like in nested where id is compared to 108 and result will be greater than 108 but it returns boolean calling function with parameters like nextIdUserInquiry(108, $con, ‘N’); and whole function body is below and mysql error is that…

Dompdf overlapping the images

I am trying to convert a products gallery images into PDF using dompdf , but it overlaps images instead of showing them on next line (for the solution, I tried <br> also but did not work for me) Here is css See 4th image is half cut and also 5th is not showing, in my css i am clearing float