I'm trying to extract an anchor tag and everything behind it from a url using preg\_replace. I found one to remove everything after the #, but I want one that removes the # and everything behind it.

<http://blah.com#removethis>

Thanks,
Steve