Custom PHP Frontend

solvx9 years ago

Hi Guys

I am using Traccar 3.5 as my tracking server (LTS 12.04 -64bit) and MySQL as database.

I am wondering if some of you have managed successfully to extract the attributes column in the positions table, using regex or similar in PHP.

I have a result like this one: {"priority":0,"sat":9,"event":0,"power":0,"io2":0,"io3":0,"io21":4,"io182":11,"io24":0,"io67":7809,"ip":"10.93.60.118"}

and like to extract the value in io67, for example.

Also do you have any custom php development scripts available?

Thank you all

Anton Tananaev9 years ago

I'm sure it's easy to parse JSON in PHP. There must be many answers on the internet.

There is also an option to extract attributes using MySQL function:

http://stackoverflow.com/a/31127857/2548565

solvx9 years ago

Thank you Anton for pointing me to the right direction.

jaimzj9 years ago