News:

Bored?  Looking to kill some time?  Want to chat with other SMF users?  Join us in IRC chat or Discord

Main Menu

styless template to work from

Started by hepp, June 07, 2005, 07:15:27 PM

Previous topic - Next topic

hepp

The default template is full of inline styles and table cellspacing/padding/width.
Is there a template to work from that is more css friendly and easier to style?

hepp

Made a quick script for it instead, hopefully I didn't forget to strip out anything

<?php
$theme_dir 
'./smb';

$dp dir($theme_dir);
while ((
$entry $dp->read()) !== false) {
  if (
substr($entry, -13) != '.template.php')
    continue;
  
$fil file_get_contents($theme_dir '/' $entry);
  
$fil preg_replace('/ (style|cellpadding|cellspacing|border|width|height|align)="([^"]+)"/'''$fil);

  
$fp fopen($theme_dir '/'$entry'w');
  
fputs($fp$fil);
  
fclose($fp);
}
$dp->close();

?>

Advertisement: