Skip to content

Pulling page guidesearch #1

Merged
merged 2 commits into from
Jul 28, 2015
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
28 changes: 28 additions & 0 deletions page-guidesearch.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
<?php
/*
Template Name: Guide Search Page
* Displays all "Pages" in the site, in alphabetical order, seperated by letter.
*/
get_header(); ?>

<div id="page-az">
<div class="row">
<div id="primary" class="content-area subpage">
<main id="main" class="site-main" role="main">
<h1>Hello</h1>
<form>
<input type="text">
<input type="button" value="search">
</form>
<?php bloginfo('description');?>
<hr/><hr/><hr/>
<h1><?php the_title(); ?></h1>
<?php the_content();?>
</main>
</div>
</div>
</div>
<?php get_footer(); ?>

14 changes: 14 additions & 0 deletions uc-guides.php
Original file line number Diff line number Diff line change
Expand Up @@ -68,4 +68,18 @@ function create_custom_guide_post_type(){

}
add_action( 'init', 'create_custom_guide_post_type', 0 );


// Add Page template via plugin...
//http://wordpress.stackexchange.com/questions/3396/create-custom-page-templates-with-plugins

function wpa3396_page_template( $page_template )
{
if ( is_page( 'guides-2' ) ) {
$page_template = dirname( __FILE__ ) . '/page-guidesearch.php';
}
return $page_template;
}
add_filter( 'page_template', 'wpa3396_page_template' );

?>