Merge pull request #26 from oreillymedia/sarah

Adding more robust handling for ulinks with and without text nodes
refactored indexterm handling and added tests