public function compile($output)
    {
        file_exists($output) || mkdir($output);

        $this->clear((string) $output);

        $this->output = (string) $output;

        foreach ((array) $this->pages as $page) {
            $folder = $this->folder($output, $page->uris());

            $html = (string) $this->html($page);

            $path = $this->realpath($output . '/' . $folder);

            file_put_contents($path . 'index.html', $html);
        }

        return $this;
    }
public function compile($output)
    {
        file_exists($output) || mkdir($output);

        $this->clear((string) $output);

        $this->output = (string) $output;

        foreach ((array) $this->pages as $page) {
            $folder = $this->folder($output, $page->uris());

            $html = (string) $this->html($page);

            $path = $this->realpath($output . '/' . $folder);

            file_put_contents($path . 'index.html', $html);
        }

        return $this;
    }
public function compile ( $ output ) { file_exists ( $ output ) || mkdir ( $ output ) ; $ this -> clear ( ( string ) $ output ) ; $ this -> output = ( string ) $ output ; foreach ( ( array ) $ this -> pages as $ page ) { $ folder = $ this -> folder ( $ output , $ page -> uris ( ) ) ; $ html = ( string ) $ this -> html ( $ page ) ; $ path = $ this -> realpath ( $ output . '/' . $ folder ) ; file_put_contents ( $ path . 'index.html' , $ html ) ; } return $ this ; }
Compiles the specified pages into HTML output.

@param  string $output
@return self
Compiles the specified pages into HTML output .