Hey guys, I'm working on a custom link shortening, similar to tinyurl. Is made in php
My problem is that I do the redirect does not support download managers.
When I add the short link to any download manager, the long url is not recognized.
This is how I do the redirect:


.htaccess:
PHP Code: 
RewriteEngine On
RewriteRule 
^([0-9a-zA-Z]+)$ index.php?id=$
index.php:
PHP Code: 
<?php
    
//$url ; get long url from database based in id
    
$url 'http://www.megaupload.com/?d=H4N9E047';
    
header"HTTP/1.1 302 Found" );
    
header'Location: '.$url.''  );
    exit;
?>
I've also tried as follows:
index.php:
PHP Code: 
<?php
//$url ; get long url from database based in id
$url 'http://www.megaupload.com/?d=H4N9E047';
header"HTTP/1.1 301 Moved Permanently" );
header'Location: '.$url.''  );
exit;
?>
any idea?
Thanks for your time.
Nan0 Reviewed by Nan0 on . Redirect url compatible with download managers Hey guys, I'm working on a custom link shortening, similar to tinyurl. Is made in php My problem is that I do the redirect does not support download managers. When I add the short link to any download manager, the long url is not recognized. This is how I do the redirect: .htaccess: RewriteEngine On RewriteRule ^(+)$ index.php?id=$1 index.php: <?php Rating: 5