Skip to content

Cipa/MODX-Evolution-HTML5-Boilerplate

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

30 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

NOTE: This is stripped down version of the HTML5 Boilerplate. Consider this a personal starting point for my projects. If you feel the need to add more functionality please submit your requests. For a full HTML5 Boilerplate implementation see https://github.com/smooth-graphics/modx-boilerplate-evo


First you need to:
--------------------
* Install MODX Evolution
* Create a chunk named GA and paste your Google Analytics code
* Create a chunk named CultureKey and enter your Culture Key e.g. en
* Install PHx http://modx.com/extras/package/phx
      
Note: if you don't what PHx just replace [(modx_charset:lcase)] with your charset

Optional Packages:
--------------------
* Install GetField from http://modx.com/extras/package/getfield


Installation:
--------------------
* Copy the assets folder and files in your MODX installation (make sure you don't overwrite the assets folder)
* If not root folder edit "RewriteBase /" to "RewriteBase /YOUR_PATH/"
* Set up a new template named Home and paste the contents of the home.tpl file
        
        OR

* Create a new snippet named Include and paste this code:
    
    <?php
        /*
        
        Snippet to include template files from file system. 
        Templates and templates resources are usually set up in assets/template/your-theme-name
        USAGE: [[Include? &tpl=`site/home.tpl`]]
        
        */
        
        if ( !isset($tpl) || $tpl== "" ) return "Missing Template file!";
        
        $tpl = $base_path .'assets/templates/'.$tpl;
        ob_start();
        include($tpl);
        return ob_get_clean();
    ?>
    
Put [[Include? &tpl=`site/home.tpl`]] in your home template(modify the existing one or create new one)

Home Template Sample:
--------------------

[[Include? &tpl=`site/parts/top.tpl`]]

<body id="template3">

    <div id="container">
        <header>
        
        </header>
        
        <div id="main" role="main">
            [*content*]
        </div>
        
        <footer>
        
        </footer>
    </div>
    
[[Include? &tpl=`site/parts/bottom.tpl`]]
    
</body>
</html>






About

HTML5 Boilerplate implementation for MODX Evolution

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published