Htaccess to redirect all calls to mp3 files to a PHP proxy

/ Published in: Other
Save to your folder(s)

Redirects all calls to mp3 files to a proxy (usefull fr example to track stats on db) the +FollowSymlinks should be already setted, but if it isnt' this setting with use it. FollowSymlinks must be on to use the rewrite engine.

Copy this code and paste it in your HTML
  1. Options +FollowSymlinks
  2. RewriteEngine on
  3. RewriteRule ^(.*)\.mp3$ /proxy.php?z=$1.mp3 [QSA]


Report this snippet


RSS Icon Subscribe to comments

You need to login to post a comment.