What are the types in the database of pl9_support_tickets.tadded and pl9_support_replies.radded? Are they strings of the correct format? I'm thinking maybe they could already be numbers. You could easily look at this (if you haven't already) by building up a string then throwing it in the template somewhere (as an html comment maybe).
Also I don't think you want "round" on the hour calculation, I think you want to use floor() or else make sure you are dividing two integer values.
|