Within the context of WordPress Theme-ing, the term 'template' refers to PHP files used to display content.

learn more… | top users | synonyms (1)

0
votes
1answer
42 views

pass html code to worpdress

I'm starting with wordpress and I have some doubts. I created a proprietary design from requirements that had. This design is made with html and bootstrap. Now I want to start using wordpress step ...
0
votes
1answer
196 views

get_template_directory() still returning path to previous theme

In WordPress, I've been installing and using various themes, including 2013, Roots, and now BlankSlate. I noticed that now that I've activated BlankSlate, the function get_template_directory() used in ...
1
vote
0answers
24 views

Different template for second page result for Ajax-loading new pages [duplicate]

Everytime I enter a posts page, index.php is called. Now on the site I load next pages (page2, page3...) with Ajax and insert the posts (just the posts) from the Ajax result inside my page. This works ...
0
votes
2answers
251 views

How can I edit the content in index.php? [duplicate]

I want the start page to be editable from a template. At the moment I can only edit the content by directly editing the HTML. Setup: Settings » Read » "Front page displays Your latest ...
0
votes
1answer
31 views

Is there any simple wordpress search template that works with existing searchforms?

I want to replace my theme's search functionality with new functionality that searches trough text widgets. Almost all content of my site is provided trough text widgets (they are static pages). Is ...
0
votes
0answers
62 views

Showing profile pages content in tabs

I've got my profile page setup which shows the users posts/comments in tabs beside each other i've added a achievement tab and would like to display the achievements users have earned. Here's the ...
0
votes
1answer
156 views

How to display custom taxonomy and terms using/creating plugin template

I am working on a plugin which requires a custom taxonomy and 3 terms (Personal, Group & Pets). I already have the taxonomy set up with terms and some sample posts. I've created a template for my ...
0
votes
1answer
39 views

How to Featured content with images in home page?

Today i saw a WordPress blog which is using Featured Articles in its home page. can any one tell me how to add that code manually to my blog only in home page. Here is the screen shot and blog url ...
0
votes
0answers
55 views

add_filter 'single_template' and use of wp_nav_menu in template

I'm using add_filter('single_template',...) to call a unique template file under a certain condition. The problem we're running into is that no matter what I do I can't use wp_nav_menu() ...
0
votes
1answer
204 views

How to add description over forum list on bbpress root page

I have few forums added for bbpress and when displaing root page I have them listed. Now I want to add some description at the top to provide some intoruction to visitors. Does anyone know how to do ...
0
votes
0answers
132 views

Wp logout working without confirmation only in header.php

If I try this in header.php: <a href="<?php echo wp_logout_url('/') ?>">[logout]</a> this works and I am logged out without asking the confiramtion question " Are you sure...." ...
0
votes
2answers
37 views

Show admin page, only if function is being used

I wrote a small function which displays a quote on the page, whenever the function is being called somewhere in a template. Since nobody likes the same quote, I created an admin page for it, where one ...
0
votes
2answers
118 views

Create Template for Custom Post Type same like for Page

I'm making my first custom theme using custom post types and I've encountered one problem. I'd like to make some templates like you can make for Pages (i.e. page-fullwidth.php page-noslider.php etc.) ...
0
votes
1answer
111 views

/wp-admin/post.php shows 404 template on submit

When I publish or save a post, I see the 404 error page from my template. This happens with posts and WooCommerce products. I'm using the Twenty Twelve theme, and I have the following plugins ...
3
votes
5answers
2k views

How to force TinyMCE in WodPress to replace newlines with <br> tags and not with <p>&nbsp;</p>

TinyMCE editor inserts <p>&nbsp;</p> instead of <br> tags when I press enter in my text for a new line. How to force TinyMCE in WP to replace newlines with <br> and not ...
0
votes
0answers
66 views

Most elegant way to create html for shortcodes?

Shortcodes seems to be very nice way to introduce complex features to the content blocks, but I don't like to generate html inside shortcode function. Instead I would like to create template file for ...
0
votes
4answers
146 views

Link to file in plugin directory from wordpress template?

I know that plugins and theme files should be kept separate but for for internal use I need to do it this way. In my themes header.php file I want to include a php file which just contains html, ...
0
votes
0answers
31 views

Enable WP to accept standard jQuery code embeding between the <body> tags [duplicate]

I don't know what is the reason that WP is not accepting the standard embedding technique from jquery website ( http://learn.jquery.com/about-jquery/how-jquery-works/ ): <!doctype html> ...
0
votes
3answers
221 views

Unable to run jQuery script in my template file

I really want to run a simple code in my template file. E.g. if I put somethign like this in my page.php: <script type="text/javascript"> jQuery(document).ready(function($) { ...
1
vote
3answers
346 views

Flush Rewrite Rules when new site is created on network

I am working with a multisite setup and I have created some custom post types, which seem to work fine except when trying to view any of the post types pages on the front end, I get a white screen. ...
0
votes
1answer
32 views

Custom template support for custom post type?

I know I can use single-{posttype}.php but can I use something like single-{custom-post-type-slug}.php to target a specific custom post type post? Or is there another way like a custom template which ...
0
votes
1answer
418 views

custom single.php not working

Trying to solve this issue for the past hour and I can't figure out what's going on. Trying to create single-blog.php (I have a few posts which are under the category 'blog') but Wordpress ...
0
votes
1answer
55 views

Archive Template being used instead of Category Template for Custom Post Type

I have a Custom Post Type created, that has its own Custom Taxonomy that give the Posts their own Categorys. I am currently building the Templates. The Custom Post Type has the slug service, and the ...
0
votes
0answers
27 views

minimum code requirements for new template

I am trying to create a very light-weight wordpress template which loads the minimum code overhead from the wordpress stack. I would like to have my template recognize that its part of wordpress, so ...
0
votes
0answers
338 views

show Visual form builder in the front end

Iam anew in wordpress . i used this plugin http://wordpress.org/plugins/visual-form-builder/ to build custom pages then i tried to build a custom page called formbuilder.php to use it in the front end ...
1
vote
1answer
113 views

Where to call wp_enqueue_script in a plugin with custom template?

I am writing my first plugin and I have this code in the main plugin php to replace home page with custom template add_filter( 'template_include', 'replace_home_page' ); function replace_home_page( ...
0
votes
2answers
132 views

Custom post type draft use wrong template

I have a custom post type called agenda with a custom post template called single-agenda.php. When I have a draft of an agenda post, this uses the content in the template single.php. When I publish ...
0
votes
0answers
83 views

Why is my no-results.php template moving my sidebar and footer into the main container?

I'm really stumped on this one but I'm hoping it's just another case of "It's late and you're missing something simple." My index.php contains an if statement: If there are posts, run the loop and ...
-2
votes
1answer
128 views

Twig+Wordpress how to use array arguments inside a function?

I already asked this on stack overflow but then I found this place. I've searched but didn't find any answer to this. I'm using a theme that was developed using the Twig template system. I don't ...
0
votes
1answer
109 views

Fake Single Wordpress Post (Page) Loop

In a plugin, I am building a custom page with add_action('template_redirect', function(){ include(TEMPLATEPATH."/page.php"); exit(); }); add_filter('the_title', function(){ return "Virtual ...
0
votes
2answers
50 views

Listing pages which uses specific template [duplicate]

I have created a template named product.php with the following header: <?php /* Template Name: Product Page */ How can I list, in a sidebar, every page that uses the "Product Page" template? I ...
0
votes
1answer
244 views

why is this content-template not showing any of my blog-entries?

i'm using the blogolife-theme on wordpress 3.6.1 my template looks like this: <?php /* Template Name: Template One */ ?> <?php /** * A custom template file. * @package WPLOOK * ...
0
votes
1answer
33 views

how to register a second page-template

i'm using blogolife http://wordpress.org/themes/blogolife and like to add another page-tamplate which is identical to the standart page-template but has a different sidebar. also i'd like to add a ...
0
votes
1answer
113 views

Fatal error: Call to undefined function the_ratings_results()

I was wondering if I rack your brains a bit on this one. I have a custom theme that has files in the theme folder but do not load as wp template files on the page settings. I also run EDD (easy ...
0
votes
1answer
50 views

How to make the first widget box to be closed instead of open in admin

When I access the Widget page in admin the first widget box is always opened no matter if I closed it in previous session or not. How to make it closed and not open? E.g. in this image you can see ...
0
votes
2answers
338 views

how to show only specific category for a template

I have a custom template which should only show posts of specific categories. What do i need to change inside this code, to get this done? if ( ! function_exists( ...
1
vote
3answers
959 views

Global variable set in the template's header.php is unable to echo in footer.php

E.g. I set this in header.php in my template: <?php $postidextra = get_the_ID(); ?> <?php $sidebar_state = get_post_meta($postidextra , 'rw_sidebar_state', true); ?> And I can echo ...
0
votes
0answers
40 views

Creating a custom menu with icon fonts

I want to create a custom menu with icon font markup. So I may need to have my list item have e.g. this: <i class="gen-enclosed foundicon-left-arrow"></i> contained inside anchor - or ...
0
votes
0answers
88 views

Customizing template menu output to fit zurb foundation markup

I want to have custom main menu markup in my Wordpress template. I want it to fit Zurb Foundation markup - to be specific - for submenus. I've figured out how to customize class & id if list ...
0
votes
0answers
29 views

Choose to show or not show title on a template?

I want to show the page title in some pages but on others I don't. I'm wondering how to do it. I thought about using differente content templates one with title and one without. But I'm wondering if ...
0
votes
1answer
47 views

List of a specific Custom Post Type in Custom Template

My WP 3.6 has created a custom template using register_post_type() named movie. I inserted few movie via Admin Dashboard > Movie. For Permalink, I have set to Post Type, therefore, for example, ...
1
vote
0answers
56 views

Search form not finding content in template page

I created some template pages on my wordpress theme and when I'm trying to do search for some words it returns Nothing Found. When I tried to search for words from the posts or normal pages(Not ...
0
votes
2answers
398 views

index.php template is used instead of blog page

I am trying to set WordPress so that home page is static, and the blog page is a separate page. So, I created two page templates in my theme., lets call them home_template and blog_template. Then, I ...
2
votes
1answer
346 views

wp_remote_get returns an error for valid URL

I currently have the following snippet of php to fetch some HTML and render it in my theme(squash theme). <?php $response = wp_remote_get( ...
0
votes
1answer
49 views

Does wp_mail work in frontend tempate file?

I am creating a function in a template that will send an email using wp_mail function. My question is if it can be used be not logged in users or not. I mean directly from a template file like (it's ...
0
votes
1answer
28 views

Will this js code work in a page template?

I have been given this code that I want to adapt and use to change a link in a template.php file, I have not been able to adapt it to work so would love any help that can be given. <script ...
0
votes
0answers
26 views

Template not properly being applied to page (no side menu)

I'm having a bit of trouble getting a particular side navigation menu applied to my sub-pages. The main page uses a specific template for the side navigation and the navigation bar displays perfectly. ...
0
votes
1answer
126 views

Make Terms Under Custom Taxonomy Use Specific Single.php Template

Yesterday some wonderful people helped me solve the issue here about templates for custom taxonomy terms. Now I have a related question. Again, I have a custom post type set up in my functions.php ...
0
votes
0answers
25 views

Stuck with custom URL REWRITE

Hello I'm creating a custom url rewrite structure for my WordPress site. First I had the following code to have url: /objekt/<GID> which loads objekt page and have query var GID. add_action( ...
1
vote
2answers
3k views

Where is get_header('shop') file in Woocommerce templates

I need to modify the get_header('shop') file in Woocommerce but don't know where it's located, if someone knows please help me out - thanks!