Javascript If Array Not Empty Php