Changeset 6705 for branches


Ignore:
Timestamp:
Jul 24, 2010, 11:00:25 PM (14 years ago)
Author:
rub
Message:

Feature 0001778: Thumbnails missing on NBM

Fix move_ccs_rules_to_body function

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/2.1/include/functions_mail.inc.php

    r6410 r6705  
    761761      }
    762762    }
     763
    763764    foreach ($selectors as $selector => $style)
    764765    {
    765766      if (!preg_match('/^(#|\.|)([A-Za-z0-9_-]*)$/', $selector, $matches))
    766767      {
    767         $unknow_selectors .= $selector.' {'.implode('; ', $style).";}\n";
     768        $unknow_selectors .= $selector.' {'.implode(";\n", $style).";}\n";
    768769      }
    769770      else switch ($matches[1])
    770771      {
    771772        case '#':
    772           $content = preg_replace('|id="'.$matches[2].'"|', 'id="'.$matches[2].'" style="'.implode('; ', $style).';"', $content);
     773          $content = preg_replace('|id="'.$matches[2].'"|', 'id="'.$matches[2].'" style="'.implode(";\n", $style).";\"\n", $content);
    773774          break;
    774775        case '.':
    775           $content = preg_replace('|class="'.$matches[2].'"|', 'class="'.$matches[2].'" style="'.implode('; ', $style).';"', $content);
     776          $content = preg_replace('|class="'.$matches[2].'"|', 'class="'.$matches[2].'" style="'.implode(";\n", $style).";\"\n", $content);
    776777          break;
    777778        default:
    778           $content = preg_replace('#<'.$matches[2].'( |>)#', '<'.$matches[2].' style="'.implode('; ', $style).';"$1', $content);
     779          $content = preg_replace('#<'.$matches[2].'( |>)#', '<'.$matches[2].' style="'.implode(";\n", $style).";\"\n$1", $content);
    779780          break;
    780781      }
Note: See TracChangeset for help on using the changeset viewer.