0
I am creating a Timeline where there may be more than one user update per day.
I need my return sql to already compare the dates and I can separate
$sql = "SELECT * FROM tb_timeline JOIN responsaveis ON id_responsavel = feito_timeline WHERE para_timeline = '".$_SESSION['id_responsavel_matricula']."' ORDER BY data_timeline ASC ";
these updates record a LOG in a table with what was changed and the date and time of change, I would like in a way that I compare the changes made in the same day and put the indicated class so that Timeline appears only on the left or only on the right.
In the image I put for each log to appear one on one side and the other on the other, however I would like to compare the dates EX: 2018-08-07 appeared on one side and the 2018-08-08 appear from another and so on
To appear on the left side, does not use class, to appear on the right side put the class Inverted"
And having two updates on the same date? What would the message look like? Unite the two in the same?
– João Martins
@Joãomartins, then he would take Order By by the time of the change
– Marcos Paulo
Ha, ok, so the goal is, in this case, to keep all of day 7 on the left side and day 8 on the right side?
– João Martins
Exactly, sorry for the delay to answer
– Marcos Paulo