<main>
<?php
    echo $cms["page"]["text"];

    try {
        $stmt = $cms["pdo"]->prepare( "SELECT * FROM pages WHERE t = ? AND created < ? AND published ORDER BY created DESC LIMIT 6" );
        $stmt->execute( array( "post", date( "Y-m-d H:i:sP" ) ) );

        while ( $page = $stmt->fetch( PDO::FETCH_ASSOC ) ) {

            include( dirname( __FILE__ ) . "/page.teaser.php" );

        }

    } catch ( PDOException $e ) {

    }
?>
</main>