0
votes
1answer
39 views

Is it possible to call a template file inside wysiwyg editor? And how?

Is it possible to call a template file, say for example mycustomtemplate.php inside the default Wordpress WYSIWYG editor? I had this content. My team (This is my content inside the WYSIWYG) then I ...
6
votes
3answers
185 views

Is it possible to override the result of get_template_part()?

I'm working on a child theme, I strongly prefer not to override the main template files in order to maintain simplicity of the child theme as well as minimize the amount of code and maintenance over ...
0
votes
3answers
65 views

How can I see what template parts are being called for rendering the viewable page?

I have a theme where the developer used get_tempalate_part() a lot, and these parts are scattered across theme subdirectories as well as in directories in a plugin that was created to assist with the ...
0
votes
1answer
99 views

Get template part vs locate template function

I'm in single.php where I'm trying to get related-posts.php template. The problem is that when using get template part the related-posts.php isn't getting custom taxonomy name from single.php in ...
0
votes
2answers
82 views

Including template pages within another template?

I've created a vertical page template which displays stacked sections (which are simply the content from other wordpress pages). I am having problems displaying the contents of pages which are ...
0
votes
1answer
622 views

Where is the template for the 'standard' format of a post in the theme twentythirteen?

I have selected the 'standard' format for a post: I am now trying to edit the layout of posts, in index.php I can see the following line: get_template_part( 'content', get_post_format() In the ...
0
votes
0answers
95 views

query_post while (have post) get_template_part()?

My goal: Is to give the user the ability, if they so choose, to create a new category. I have the current categories saved in a separate php file and call them in using get_template_part(), there ...
1
vote
1answer
34 views

Valid HTML in Template Part

in a custom plugin I have a WPQuery, which looks like the following: $sticky = get_option( 'sticky_posts' ); $args = array( 'post_type' => 'mission', 'ignore_sticky_posts' ...
0
votes
2answers
74 views

Remove portion of header code from home page only

I have this code in the template file header.php: <div class="dynamic-header"> <?php if(function_exists('show_media_header')){ show_media_header(); } ?> </div> I want to ...
8
votes
3answers
1k views

Is there any way to use get_template_part() with folders?

I'm wondering if there is any way to use get_template_part() with folders? My main folder has a lot of files now because I put every re-usable element in a separate file. I'd like to put them in ...
0
votes
1answer
223 views

Use a separate template for the home page only

I use Pinboard theme (it has a very complicated structure, but it is nice). Image how it works Select a template in this way it changes for all posts, pages, etc. and do not give you more choice. I ...
0
votes
2answers
129 views

Organize template parts and page templates in folders in regards of template hierarchy

Hello and happy new year Suppose one has a large theme composed of several post types, page templates and a bunch of custom loops and template parts which is best keeping in separate php files. ...
2
votes
1answer
2k views

passing argument to get_template_part() or a better way to code

I have this include … event-list.php <?php /** * The loop that displays upcoming events */ ?> <ul class="event-items"> <?php $yesterday = time() - 24*60*60; $args = array( ...
2
votes
2answers
490 views

How to move style from template file to <head> section?

Imagine the following situation: //header.php contains: <header id="header">logo and navigation</header> //my-template.php contains: <?php get_header(); ?> <style ...
0
votes
1answer
96 views

Taxonomy template for all taxonomies attached to certain post type

For instance, I have a product post type and I would like all the taxonomies associated w/ this type, such as size, color, material etc to display using the same template without having to 1. create a ...
0
votes
2answers
391 views

TwentyTen: Overloading template.php files vs. get_template_part

I'm studying TwentyTen, under the assumption that it contains the best practices for writing themes and modifying them using child themes. I'm noticing what looks like a really redundant practice, ...
2
votes
1answer
501 views

Possible to use pagename inside get_template_part?

I'd like to grab the current page name and pull that specific template part per page. This way I can just set up a generic tier-1 template that calls in a secondary section based on the current page's ...