You can use a break in the inner loop, and that should exit to the outer loop and finish it. If there's code after the inner loop that you want to skip you can create some bool and set to true to continue in outer loop. Since I probably explained this poorly here are some code examples:
PHP Code:
for (int i = 0; i < SOMENUM; i++)
{
for (int j = 0; j < ANOTHERNUM; j++)
{
if (SOME_CONDITION)
break; // exits to outer loop, which will end current outer loop iteration
else if (ANOTHER_CONDITION)
continue;
}
}
For skipping other code after inner loop:
PHP Code:
for (int i = 0; i < SOMENUM; i++)
{
skip = false;
for (int j = 0; j < ANOTHERNUM; j++)
{
if (SOME_CONDITION)
{
skip = true;
break;
}
else if (ANOTHER_CONDITION)
continue Inner;
}
if (skip)
continue;
// some more code
}