Php Array Push If Not Null Javascript