How can I rewrite this please as I tried a few things and I just dont know the correct way to do it. Instead of:
$files_to_zip = array(
1,
4,
8
);
How can that be rewritten so that:
$explode_mods = "1,4,8";
$mod_nums = explode(",", $explode_mods);
$files_to_zip = $mod_nums;
Basically $files_to_zip still needs to be in array format but I don't know how to only display each value into an array for the $files_to_zip variable. This is part of a larger script and I am almost done so please do not show me a totally different code I just need $files_to_zip to be read as an array still. The $explode_mods will actually be a $_POST value in the real script where I enter numbers separated by commas and they will be inserted into the $files_to_zip array. Thank you.
$files_to_zip(and$mod_nums) will be an array, containing the the elements1,4,and8.