I have coolURI installed and use the following code.
baseURL = http://www.my-domain.org/
tx_cooluri_enable = 1
redirectOldLinksToNew = 1
simulateStaticDocuments = 0
prefixLocalAnchors = all
if you use baseURL every URL is based on it, even local anchor URLs like '#'.
Either you change your template and insert the URL of the current page
or you avoid baseurl as recommended and use 'config.absRefPrefix' instead.