There are different reasons for different engines to add 301 redirects not in .htaccess. For DLE, PHP redirects are the only way to avoid looking at dynamic garbage generated in links.
Examples implementation in PHP:
if ( getenv('REQUEST_URI') == '/page-before-redirect/' ) { header( "HTTP/1.1 301 Moved Permanently" ); header( "Location: http://old.domain.com/page-after-redirect/" ); exit; }
if ($_SERVER['REQUEST_URI'] == "/page-before-redirect/") { header('HTTP/1.1 301 Moved Permanently'); header("Location: http://old.domain.com/page-after-redirect/"); die('redirect from page-before-redirect'); };