I'm trying to port some exsiting templates to PHP and need to do includes inside of JavaScript document.write('Use PHP to include stuff here'). The include is adding a trailing CRLF which then breaks the JavaScript code.
What I need is:
START<?include('/foo/bar/file.html');?>END
To produce:
START[[String in file]]END
But I'm getting
START[[String in file]]
END
I've tried to use require() but it will also add an extra CRLF after including the file. Any ideas???
-Kevin