开发者

yui css compiler - accept input from php file

I'm trying to pipe all the content from a PHP generated file to YUI CSS compressor.

// this command works great for Google Closure Javascript Compiler
php jscompressor.php | java -jar compiler.jar --js_output_file compressed.js

php jscompre开发者_StackOverflow社区ssor.php pulls up a PHP file that has a lot of generated JS.

I was hopping I could do exactly this but with YUI.

I cant.

// can anyone help me on this one? the following code doesnt work
php csscompressor.php | java -jar yuicompressor-2.4.2.jar -type css -o cssyui_compiled.js

Thanks in advance.


I had a typo on the type. Now works as expected.

// the following command pipes all output from csscompressor
// into YUI for CSS compression
php csscompressor.php | java -jar yuicompressor-2.4.2.jar -o cssyui_compiled.js --type css

Hope it may help someone! ;)

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜