Linking to anchors in Joomla 1.0.12

creating a small component for Joomla myself, I got into the problem to link to an anchor while having SEF (search engine friendly Urls) enabled. Searching the Joomla forum got me to some helpful topics: Anchors in templates with SEF and this one. So you have to use <a href=“<?php echo sefRelToAbs( ‚index.php?‘. $_SERVER[‚QUERY_STRING‘] . ‚#blabla‘ ); ?>“>Content</a> to get to an anchor on the current page!