in reply to Perl and Shell (text conversion)
Firstly, thank you to the contributors for their responses and insights, especially links to relevant docs!, it will definitely be useful in the future.
You are indeed correct and I had missed passing any arguments to the function, which naturally wouldn't do anything.
I had read that pandoc is a better/safer method and I think I will suggest this instead of the potentially unreliable conversion it is doing now.
Thanks Monks!