[thelist] parse file.js with PHP

Hassan Schroeder hassan at webtuitive.com
Thu Jun 27 09:40:06 CDT 2002


"Means, Eric D" wrote:

> > I need to parse a file.js file with PHP. Should I:
> > - call it file.php? (easiest, but can I do that?)

> Calling it file.php is probably a bad idea, because some browsers may want
> it to be served as text/javascript or whatever, which could cause issues.

No, /not returning a proper content-type header/ is the bad idea;
the file's name/extension is irrelevant.  :-)

--
H*
Hassan Schroeder ----------------------------- hassan at webtuitive.com
Webtuitive Design ===  (+1) 408-938-0567   === http://webtuitive.com

    -- creating dynamic Web sites and applications since 1994 --



More information about the thelist mailing list