meledak lepaskan php kosong

implode('-', array_filter($array));
Helpful Hawk