Returns a 1 if the position has modules or a 0 if the position does not have modules.
Example:
<?php if (hasModules('left')) modules('left'); ?>
We've got all the documentation you'll need right here.