renaming multiple files (bash)

I had to rename many .phtml files, so that their extension will change to .php. This does the trick:


for i in *.phtml; do mv $i ${i%.phtml}.php; done

Comments

colorized code in posts

This seems to work: (from the command line. php cli needs to be installed)

echo "" | php -q > file.html

Upload the resulting file and link it to the post as appropriate.

Comments

php and (la)TeX

I often need to format reports such as phonebooks. It’s hard to get any better than TeX, so I like to combine them More… »

Comments