Ah, in that case you can use:
```php
if($planet->hasStockpile()) {
	foreach ... {
		...
	}
}
else {
	$PHP_OUTPUT.=(' Nothing!</p>');
}
```