Skip to main content

All Questions

Tagged with
Filter by
Sorted by
Tagged with
11 votes
7 answers
17k views

Conditional tag to check if 'page.php' is being used?

I'm trying to check whether the page.php template is being used or not. I've tried is_page_template( 'page.php' ) but it doesn't work. I also can't use is_page() because I only want to do something ...
user1981248's user avatar
  • 1,067
0 votes
1 answer
441 views

Specify parent page template

I don't want to define a template from admin because I have lot of page and so if I change it I might forget my selected template. So I want make that template in page. Here is my page structure ...
Accore LTD's user avatar
0 votes
0 answers
38 views

WP Template Hierarchy - Need help choosing the correct templates

Please see this image to get a better understanding of what I would like to achieve. Please pay attention to point #3 and #4 (notice the permalink structure). The "Homepage" is static (front-page....
William's user avatar
  • 207
0 votes
2 answers
3k views

Load new Posts on Scroll on Page

See this reference site: http://alwaysjudging.com/archive/ It's loading new posts on scroll down, similar to Infinte Scroll plugin. (But I'm unable to get the Jetpack Infinite Scroll plugin to work on ...
melissa's user avatar
  • 21
0 votes
2 answers
8k views

the_content of template page

When I use the_content in the page-template doesn't show anything. Loop to call the page-template in the index: index.php <?php /** * Main template file * * This is the most generic template ...
dborghez's user avatar
  • 129
0 votes
2 answers
190 views

How to edit a HTML list in WordPress?

I'm new to WordPress and what I want to do is to edit the HTML of a specific page in WordPress. For example, a page in my website shows in the source code (in Chrome) a list, that I can see in the ...
user3614001's user avatar
0 votes
1 answer
2k views

Custom Filter using meta_value in wordpress admin list not working

Hello I was trying to filter the pages using a custom filter in admin post listing of wordpress, but after selecting in the dropdown it returns nothing like its just showing all the posts and the ...
Kiko Lolo's user avatar
0 votes
1 answer
846 views

Changing permalink name redirects to another template?

I'm creating a template with a few templates with names page-contact.php, page-portfolio.php and page-blog.php. The problem is that when I select a Defaul Template for a page (I expect it to open ...
Ziik's user avatar
  • 191
0 votes
2 answers
2k views

Use page template for custom $_GET content

I have a list of products, and I want to be able to click a link and get to a page with more information about the product, which I can do using $_GET like so: $s .= '<p><a href='....
Ollicca Mindstorm's user avatar
0 votes
2 answers
57 views

How to use custom page templates in a theme that hides page template option?

My client uses a theme called "Imbalance2", which hides the template option in dashboard "page attributes" section. Is there a way to assign a custom template to a page despite this - rather ...
drake035's user avatar
  • 1,197
0 votes
1 answer
109 views

Print the whole page?

I am trying to make a loop to loop all pages beneath each order. I want this because I want to make a one-pager with a page as an element of the one-pager. So that you can go into WP to edit a page ...
Maartje's user avatar
  • 547
1 vote
1 answer
102 views

Page Automatically Generated from Theme?

I'm running WordPress multisite and would like each site to have a specific page (with pre-loaded content) generated from a page template, contact.php. Rather than go through each site and create this ...
AndrettiMilas's user avatar
0 votes
1 answer
66 views

Setting a new default template for the creation of a page

Right off the bat I would like to say that I am a WordPress noobie, so I'm really sorry if I infuriate you. I've recently taken over the management of a clients website an have been sent a request to ...
Chetan's user avatar
  • 3
0 votes
1 answer
1k views

get_template_part() to render single page Theme

I´m developing a single page theme and want to render all pages with their respective templates on a single page. I know I could make a query and write the markup for the respective page, but I prefer ...
brubs's user avatar
  • 103
3 votes
2 answers
2k views

Is including the loop necessary for page.php? [duplicate]

QUESTION: Is it necessary to include the wordpress loop in page.php? If it is not necessary, why do many themes (including the wordpress 2013 default theme) include it? I noticed this discussion on ...
Daniel Dropik's user avatar
0 votes
1 answer
87 views

how bbPress and buddypress add their own page templates to the page template drop down on the page editing screen

Im writing a plugin and need to know how to add a page template in the edit page screen from within a plugin. bbPress and Buddypress both add page templates to this drop down and I can't figure out ...
rashid's user avatar
  • 223
0 votes
1 answer
252 views

change top banner content on specific page

I have a static top banner on my website build like this : <div class="row-fluid top-banner"> <div class="container"> <div class="banner-overlay"></div> ...
agis's user avatar
  • 421
0 votes
1 answer
112 views

Remove comment section from new page

I am taking over a wordpress website at work. All of the pages currently do not have a 'Leave a Reply' comment section. When I make a new page, this section exists on the new page. How do I remove it? ...
David Tunnell's user avatar
2 votes
1 answer
6k views

Custom Blog Post Listing in Genesis Sample Child Theme

I want to add several images and divs and also customize the look of my Blog post listing... But i can't find the way to do it. Here's the Blog Template code <?php /* WARNING: This file is ...
Jeremi Liwanag's user avatar
1 vote
0 answers
67 views

Could be a namespace conflict (?) with login form and register form on the same page

I have created a "My Account" page template for WP 3.5.2 that displays certain custom data if a user is logged on. If not, the page displays a login form and a link that opens the register form in a ...
Mophilly's user avatar
-1 votes
1 answer
468 views

exclude page element from specific pages

I'm using a specific navigation menu that should be present on all but two pages. How can I exclude <div class="portfolio-nav"> from the specified pages(About & Contact)? <?php ...
user1255049's user avatar
0 votes
0 answers
36 views

Showing certain page without redirection

I need to get any url that starts with "booking" to lead to certain post without redirection. That means all of these URL would lead to post Booking, but the URL would stay the way it is: example....
Draex_'s user avatar
  • 111
0 votes
0 answers
93 views

Make a custom URL and link to custom Template

I have a set of categories in my WP site. I also have a "team" thing in my site. Now when a user makes a new post he selects a category and then chooses the team to which post belongs. I have added ...
Sankalp Mishra's user avatar
0 votes
1 answer
73 views

Custom theme template files

Im trying to create a Theme from scratch, its quite challenging, cause im new to WP. I follow this developing process at Teamtreehouse. All is very good, its just, im puzzled with the template file ...
Linards Berzins's user avatar
0 votes
1 answer
58 views

Page template with custom html fields inside a content

I'm writing a custom page template and I want to do something like this: after typing tag inside page content, for example [custom-email-form] I want to place inside the content some html5 email form. ...
user1760395's user avatar
0 votes
1 answer
3k views

How to dynamically change spots of text in custom page?

When I create a page I'm suppose to describe the content on the editor of Wordpress. When it's a simple text with some images its ok. But the problem is: My custom layout has a lot of deep HTML and I ...
Luccas's user avatar
  • 101
0 votes
2 answers
329 views

Interrogate a page within a loop to check template type or custom meta data (Pages vs Posts)

I've spent a few days researching working with WP static pages - as separate from posts. Although I've found useful guidance, I can't seem to find any good tutorials or worked examples that show me ...
Paul Zee's user avatar
0 votes
1 answer
271 views

What's the most minimal way in which a page can be hooked into WP?

I do a fair bit with custom API's on WordPress-based sites, typically by creating page templates. However, creating a custom page template, then creating a WP Page that utilizes it is kind of a pain ...
John Rork's user avatar
  • 121
0 votes
1 answer
676 views

Wordpress theme: Add page content to the bottom of the Contact form

I am using the following wordpress theme, which is pretty cool btw.: http://demo.s5themes.com/?theme=simplecorp Now the site has a custom Theme Options build in, where you can specify all the content ...
David Van Staden's user avatar
0 votes
2 answers
130 views

Create a new page for each form selection

I have a got custom page template which displays a drop down box that has list of countries.A user selects the box and clicks sumbit.Page then then displays the relevant details for that country .IT ...
naf's user avatar
  • 1
0 votes
1 answer
450 views

Using custom post types within a section of a template

I'm trying to get the hang of custom post types and I am trying to get them to loop through the post types within a page template. I'm already using the MultiEdit plugin to display certain content ...
ultraloveninja's user avatar
2 votes
1 answer
849 views

Do I really need the div class entry?

I was wondering if it's really neccessary to keep the <div class="entry"> in the page.php file (or any other template for that matter). I typically use a blank HTML5 wordpress theme and it doesn'...
ultraloveninja's user avatar
0 votes
1 answer
1k views

How to bypass 404 for certain pages/posts?

I have a site with urls like so: site.com/folder/page-name It is moving to another site built in wordpress and I am trying to recreate the page to ensure incoming links continue to work as normal. ...
BillyMedia's user avatar
14 votes
2 answers
180k views

How to display page content in a page template?

In my WordPress site, I made a custom page template, which contained a custom query [using WP_Query()]. With that query, I can perfectly get the posts of a certain category. But I want to show the ...
Mayeenul Islam's user avatar
0 votes
3 answers
9k views

Dynamic href link to Contact Page

I need a <a href="Something Like <?get_contact_page>">Contact Page</a> Code that always links to the Contact page, no matter what is it's ID There's a page template for contact page....
Lucas Bustamante's user avatar
1 vote
1 answer
117 views

Create a loop that gets pages with their template

I am trying to make a template that will be an html5/ vertical scrolling base. I have created an amount of page templates that each would represent a <section> on index.php which mainly all it ...
Panagiotis's user avatar
0 votes
1 answer
70 views

Outputting content from page

I'm trying to display a title, featured image, and content from a page into a new template (that will contain content from several pages). I tried to just echo the variables as shown below, but right ...
mtthwbsh's user avatar
1 vote
2 answers
1k views

Removing the TinyMCE editor for a given page template

I was looking for a way to remove the TinyMCE Editor for a specific page template in a theme (in my case it's page-home.php). I found the following code, which works, however, I was wondering if this ...
Ian Muscat's user avatar
0 votes
1 answer
1k views

Prevent menu from loading in a page template [duplicate]

Possible Duplicate: Remove navigation from header in custom page template Is there some way to remove wp_nav_menu in a page template? I can't find anything related to page templates other than ...
Diana's user avatar
  • 1,248
2 votes
3 answers
2k views

What are the differences between "Latest Posts" and "Static Page"?

WordPress has an option to pick "Latest Posts" and "Static Page" under "Settings" in Admin Panel. My questions: What page template is getting loaded in each of those modes? Why paged stops working ...
Atadj's user avatar
  • 2,182
26 votes
2 answers
31k views

Getting only direct child pages in WordPress with get_pages

I am trying to fetch all direct children of a page. But I am getting all children and grand children as well. Any ideas? PHP Source: $args = array( 'child_of' => $post->ID, '...
lejahmie's user avatar
  • 373
2 votes
1 answer
378 views

How to dynamically save a selected option from page "Templates" selectbox?

When I select a template for a page from the "Templates" selectbox, the selected item gets “value=selected” only after I hit save draft/publish/update. <option value='template-gallery.php' ...
Madalin's user avatar
  • 95
0 votes
1 answer
26 views

link a custom page into menu

Ok i have a file which named, page-allpost.php now I have a menu item called "all post" and in that menu I want to call the page-allpost.php which will display all the post. how to do that? hope ...
Juliver Galleto's user avatar
1 vote
2 answers
2k views

Single page theme that uses pages for the content

I'm making a one page site. On the page I want to run WP_Query three or four times to pull in those 3-4 pages. The page looks a bit like this: <div class="row"> <?php $args = array( ...
saltcod's user avatar
  • 2,098
6 votes
5 answers
9k views

Wordpress page edit does not save selected template

The feature did work in the past however pages now seem to default to 'Default Template'. I can see my available page templates in the drop-down on the Page edit page, however after saving the admin ...
Ingmar Boddington's user avatar
3 votes
2 answers
863 views

How do I modify this page template to show subpage excerpts (not post excerpts)?

I have made a page template which shows linked subpages using this bit of code: <?php $mypages = get_pages( array( 'child_of' => $post->ID, 'sort_column' => 'menu_order', 'sort_or ...
paradroid's user avatar
  • 195
2 votes
2 answers
2k views

How to make certain page templates visible to admin only

Making a site for a client, I have some pages that the client won't be able to edit or delete. These pages rely on specific page templates. However, I don't want these templates to be available for ...
INT's user avatar
  • 1,281
0 votes
2 answers
63 views

Can You Build Page Templates Without Extra Files

I'm very familiar creating page templates in WP and for this project I really just have one page template with an option to switch the sidebar from the right side to the left side. The problem is that ...
BFTrick's user avatar
  • 941
5 votes
2 answers
4k views

Set page template automatically based on parent

As the title implies, I'm trying to set each new page under X parent to a specific page template. Either through a function/plugin/code eg: if I make a 'swiss cheese' page, that is a children of the ...
alme1304's user avatar
  • 173
1 vote
2 answers
134 views

Determine page content based on page parent

How can I display a gallery shortcode for pages who are children of the page with an ID of 9, and the regular content for pages who aren't? This is what I've tried so far, but it's not working: <?...
Phantasmix's user avatar