예제 #1
0
 /**
  * Remove the custom css file for a layout
  *
  */
 public function RemoveCSS($layout)
 {
     global $gpLayouts;
     $path = $this->LayoutCSSFile($layout);
     if (file_exists($path)) {
         unlink($path);
     }
     $dir = dirname($path);
     $path = $dir . '/index.html';
     if (file_exists($path)) {
         unlink($path);
     }
     if (file_exists($dir)) {
         \gp\tool\Files::RmDir($dir);
     }
     if (isset($gpLayouts[$layout]['css'])) {
         unset($gpLayouts[$layout]['css']);
     }
     return true;
 }