1
2
3
4
def compress(source)
    source.gsub!(/\s+/, " ") # collapse space
    source.gsub!(/\/\*(.*?)\*\//, "") # remove comments - caution, might want to remove this if using css hacks
...

Ruby Gsubing

by marko.z, October 31, 2008 09:44, 2 refactorings, tagged with ruby, string, css, gsub

There is a lot of repetitio...

Bd9893bfd15fa7b443d112607b937734 Talk
1
2
3
4
<?php if ( the_ID() == 8) {
echo "<div id='menu_show' class='slideshow'>
  <img src='http://www.someone.com/wp-content/themes/True%20Nature/img/rotate1.jpg' alt='A picture' width='748' height='245' />
...

PHP Output div block with PHP c...

by K, December 07, 2007 18:53, 6 refactorings, tagged with css

Hi, I am just scratching th...

B5ae59b19cc356df333baffffb9f2c91 Talk