Hi! I have a question regarding the .htaccess file. I have several files named something.js.php that look like this: <?php header("Content-type: text/javascript; charset: UTF-8"); ?> //javascript starts here function something() { document.write('Hello'); } Code (markup): My question is... How do I remove the .php extension with the .htaccess file? So the file would be called like something.js and still being parsed as php by my server Thanks a lot!
There is a trick to do such task among those I posted a few days ago, but you need to pay a visit to such website to find it out, http://forums.digitalpoint.com/showthread.php?t=240756
Thanks a lot! Worked like a charm! Just a quick fix, to make it work I had to put it like this: RewriteRule ^(.*).js$ $1.js.php [nc] Code (markup):