[thelist] ASP (not .net) script to pre-compile + cache multiple CSS files?

Jonathan Snook jonathan.snook at gmail.com
Tue Jun 26 18:58:21 CDT 2007


On 6/26/07, Jon Hughes <hughesj at firemtn.com> wrote:
> I have seen this done with PHP, and semi-done with ASP.NET, but I cannot
> for the life of me find a script that will pre-compile multiple CSS
> files into one, then serve the full css file to the client (thus having
> only one HTTP request)
>
> Anyone have any ideas on this?

Using the FileSystemObject, this should be a relatively
straightforward task. Create a function that takes an array of file
names. The function loops through each one, grabbing the files and
feeds it to the browser. You could add in caching as well by writing
the result to its own file. and then just reading that on subsequent
requests.



More information about the thelist mailing list