index.php 716 B

123456789101112131415161718192021222324
  1. <?php
  2. /**
  3. * The main template file
  4. * This is the most generic template file in a WordPress theme
  5. * and one of the two required files for a theme (the other being style.css).
  6. * It is used to display a page when nothing more specific matches a query.
  7. * E.g., it puts together the home page when no home.php file exists
  8. *
  9. * Methods for TimberHelper can be found in the /lib sub-directory
  10. *
  11. * @package WordPress
  12. * @subpackage Timber
  13. * @since Timber 0.1
  14. */
  15. $context = Timber::context();
  16. $context['posts'] = new Timber\PostQuery();
  17. // $context['logo'] = '';
  18. $templates = array( 'base.twig' );
  19. if ( is_home() ) {
  20. array_unshift(' accueil.twig' );
  21. }
  22. Timber::render( $templates, $context );