Tagged Questions
0
votes
0answers
17 views
2) Adding Page Attributes Metabox and Page Templates to the Posts Edit Page? [duplicate]
I cannot ask directly to the post.. So I will try to ask here.
On the Question: Adding Page Attributes Metabox and Page Templates to the Posts Edit Page?
On Answer 3 There is a breakdown of 7 steps.
...
0
votes
1answer
31 views
Which hooks are essential for post templates?
Im in the process of building a very custom theme and Im beginning to work on the post templates, but I dont know which hooks are essential for them.
So like, I've seen (but cant remember where)some ...
0
votes
1answer
34 views
How do I disable the “by author” hyperlink on posts?
I'm trying to disable the "author" hyperlink when making a post, but having no success.
How can I do it?
0
votes
1answer
63 views
Display the first post's comments of category in comments.php template
I want the display the comments from first post of the category only.
Example;
Category
- Post 1 (2 comments)
- Post 2 (1 comments)
- Post 3 (5 comments)
If I am reading the Post 2 or Post 3, I ...
0
votes
2answers
63 views
Trying to query all posts in category 4
I have the following template page. I am attempting to output all of the articles from the category 4. However I am only getting some of the posts, about 20% of them. Not sure what would be causing ...
0
votes
2answers
39 views
1 post, 2 templates
I want to be able to render post in two different styles (2 templates).
For example, let's say I have the post ID 133, I would like two URLS to access it and so it renders where different template ...
0
votes
2answers
49 views
How to create a template for Pages?
In Wordpress, when creating a page, it shows some options for Template under Attributes, such as: Default, Links, One column no sidebar, etc.
Is there a way to add more custom templates to show up ...
0
votes
2answers
122 views
How do I stop the loop from repeating in my category template?
For some reason, when viewing a category, the posts are repeated - basically the whole loop repeats as many times as there are posts for that category.
E.G.:
If category_a has 3 posts, the page will ...
0
votes
1answer
318 views
previous_post_link() and next_post_link() with a custom post type?
I'm on single-work.php for a custom post type called work, inside the loop.
Trying to make two links to the previous and next post.
Using this code:
<?php previous_post_link(); ?>
and
...
3
votes
3answers
333 views
Setting a custom sub-path for blog without using pages?
Warning: fairly pedantic request ahead.
I have a design that makes use of posts (I.e., the blog) and a custom post type called "howto". The site front page ("/") has a template that displays the ...
1
vote
4answers
422 views
How only display all post related to category
I'm trying to make a custom template for my category pages that only pulls in post under a specific category. At the moment, I am only able to pull in all post and not category specific...
My code so ...
0
votes
2answers
248 views
loop not displaying posts on custom template page
I have a site using a static homepage, and a posts page called Press(press.php).
The template is being pulled up correctly, however no posts are shown.
Any ideas why? Thanks in advance.
Live site.
...
0
votes
2answers
64 views
posts not showing on index.php
Live site.
I've got a custom theme, wherein the homepage(front-page.php) is static and the "posts" page is Press(index.php). Everything with the theme works great, with the exception of the posts not ...
0
votes
1answer
124 views
Output Buffer Issue with Single Post View
I created the following function that I am using to load single post views:
// Post
function basey_single_post() {
global $post;
ob_start();
echo apply_filters('basey_page_title_news', ...
0
votes
1answer
31 views
how to style an individual page in a category [duplicate]
Possible Duplicate:
How to show a post single post in page template
im trying to understand how to target a template for an individual post.
if i use the following hierarchy for my site,
...
0
votes
1answer
116 views
Category Template: Need to display different content on first page of archives
So my issue is that I need to create two versions of a category.php template. Now, I know very well that if I want to display posts from just one category, I duplicate category.php and call it ...
1
vote
2answers
433 views
add_rewrite_rule and template redirect not working
I have a strange problem , I have the following pairs :
add_rewrite_rule('^questions/ask/?','index.php?pagename=ask','top');
if(is_page('ask')){
$tname = 'add-question.php';
...
2
votes
1answer
249 views
Post/Page Preview Template
Is there a way to have a custom template php file that is only used for previews instead of it using the single.php file? This way the user knows they are in preview mode?
1
vote
3answers
415 views
posts page - different lengths of excerpt
is it possible to get wordpress on the posts page to do the following example.
the first three posts need to have a large image spanning the width of the title box and a longer excerpt.
the rest of ...
0
votes
1answer
662 views
Use template of parent category for single post sub-categories
I have single post templates in a folder in my child theme marked "single". I need the sub categories to use the same template as their parent. I've read a dozen tutorials all of which were more than ...
0
votes
1answer
70 views
How to display a certain template element only for posts published within certain time range?
I recently migrated a blog from sub.domain.com to blogs.domain.com/sub/. Because I'm using Facebook comments, all the posts published before April 25 need to reference sub.domain.com/blog-entry-title ...
0
votes
1answer
178 views
Why won't pagination work?
I am using a page template with code to display all blog posts:
<?php /* Template Name: Blog */ ?>
<?php get_header(); ?>
<div id="main">
<?php
// ACF Page number variable
...
2
votes
2answers
540 views
How to display different single post template based on author?
My current singlepost.php makes use of the following if conditions and renders the appropriate template.
<?php
$post = $wp_query->post;
if ( in_category('4') || in_category('59') ) {
...
0
votes
2answers
498 views
Single post as homepage?
I'm wanting to set a single post as my homepage.
I have a photographer's site.
There are a few galleries (weddings, portraits etc). Each gallery is a wordpress post with attached images.
The post ...
1
vote
1answer
392 views
Change post_date to post_modified date on post template?
I'm looking to change the post created date to a modified date on my post template (single.php). Moreso, I'm looking to control when I update that date based on whether I make significant changes to ...
0
votes
1answer
726 views
Prevent 404 of Author pages without posts
How do I prevent author archives without posts from 404ing?
0
votes
1answer
619 views
Redirecting posts in Wordpress to a specific page
I created a page so that it would appear in my navigation menu. This page would however be my posts page (i.e. all posts would go here) and would also be my front page.
I am unable to find anything ...
0
votes
1answer
335 views
Creating / Editing a post from within site template
I am developing a website that will allow multiple users to author short posts (Kind of like a job board) and I want to know how they can author or edit these posts from within the site template (Ie; ...
1
vote
3answers
2k views
Display page content AFTER a loop of posts
This is probably easy once you know but I'm having trouble getting the static page content to appear AFTER a list of posts.
I'm using a named page template which displays posts as a slider and I want ...
3
votes
2answers
483 views
How to get Images included in Post
is possible to get images added to a post programmatically? I am working on custom template (my first) and I need to display Images added to a post in specific way.(first image as title image and the ...
0
votes
1answer
2k views
Custom post type and taxonomy page templates
This is my first real delve into custom post types and taxonomies, i suppose it will all come to me in a flash of inspiration but right now i have confused myself beyond all realms of possibility and ...
1
vote
1answer
433 views
Using custom post template
i'm trying to implement a custom post template for all posts filed under a specific category.
I'm making use of WP-O-Matic plugin that puts in the RSS feeds in this category and would like to make a ...
0
votes
1answer
255 views
Creating separate feeds for custom post types
My site has a few custom post types, news, events, you-tube, etc. I'd like to create an rss feed for each post type as well as a main with all.
I've experimented an bit and found how to combine them ...
2
votes
1answer
123 views
Is it possible to have two different previews of a post (ie. two templates for one post)?
I'm looking for a way to allow post editors to see two different previews of the posts they are writing. On the front, the same post can appear it two different sections of the website (each shows a ...
0
votes
1answer
149 views
Is it possible to give the user the chance to select between two single template files to use in a post?
Basically, I want to allow the user to select which template files he or she wants to use in a post:
single-asc.php:
<?php $custom_posts = new WP_Query(); ?>
<?php ...
2
votes
3answers
1k views
Grid layout “last” class to every third item
Seems like a trivial problem but I can't get it to work. I need to add class="last" to every third post.
Here is my code:
<?php
$count = 0;
$my_query = new ...
1
vote
2answers
540 views
How to support custom templates on a custom post type?
I'm stucked at some point developing my theme.
I created a custom posts types to support an image gallery. So far, it's working great (have a look on 'galeria' on psaikali.com).
I registered this ...
6
votes
2answers
9k views
Adding Page Attributes Metabox and Page Templates to the Posts Edit Page?
(Moderators note: Title was originally "How can I add the "Page Attributes" and/or "Page Attributes > Template" selector to POSTS editor")
WP currently only allows the assignment of a "template" to ...