Permalink
Cannot retrieve contributors at this time
Name already in use
A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
dmd-wp-theme/page.php
Go to fileThis commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
executable file
27 lines (26 sloc)
845 Bytes
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* The template for displaying all pages. | |
* | |
* This is the template that displays all pages by default. | |
* Please note that this is the WordPress construct of pages | |
* and that other 'pages' on your WordPress site will use a | |
* different template. | |
* | |
* To generate specific templates for your pages you can use: | |
* /mytheme/views/page-mypage.twig | |
* (which will still route through this PHP file) | |
* OR | |
* /mytheme/page-mypage.php | |
* (in which case you'll want to duplicate this file and save to the above path) | |
* | |
* Methods for TimberHelper can be found in the /lib sub-directory | |
* | |
* @package WordPress | |
* @subpackage Timber | |
* @since Timber 0.1 | |
*/ | |
$context = Timber::get_context(); | |
$post = new TimberPost(); | |
$context['post'] = $post; | |
Timber::render( array( 'page-' . $post->post_name . '.twig', 'page.twig' ), $context ); |