SiteInvoice - invoices
-
semias
Where is the install/siteinvoice/index.php used for?
-
semias
- State changed from open to resolved
Cause: A foreach loop is executed according to the following parameters:
foreach($array as $key => $value) { actions; }If $array is empty/null, it results in a warning because a system simply cannot assign values to non-existing keys.
Solution: To fix these types of issues, a simple if loop has to be added before the foreach loop is executed to check whether or not $array is empty.
if ($array) { foreach($array as $key => $value) { actions; } }This means the foreach loop will be skipped altogether if $array is empty/null.
Please Sign in or create a free account to add a new ticket.
With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.