I have an array that have an index 0
and index 1
and in some cases the index 1
will not be exist. I want to bypass it and pass only the index 0
or i want to create it and add value to it.
$eq = explode(" - ", $div->textContent) ;
$p_part_one_name = $eq[0] ;
$p_part_two_name = $eq[1] ;