I have images missing between pages
The return path from path_to_theme() doesn't have a slash at the front of it and so becomes relative to the path you're currently at. That would probably explain why it works for pages in the root of your site, but not those that are at least one directory down.

You should be able to fix it easily by adding a forward slash to the start of the image path:

&lt;img src="/&lt;?php print path_to_theme(); ?&gt;/images/brand_icons.gif" alt="" /&gt;


On another note, make sure you fill the alt in...people with screenreaders will thank you for it :)