The single post template. Used when a single post is queried.

learn more… | top users | synonyms

0
votes
1answer
80 views

Single custom post type page redirecting to 404 page

I have declared post type as below: $args = array( 'labels' => $labels, 'public' => true, 'publicly_queryable' => true, 'show_ui' => true, ...
0
votes
1answer
32 views

Link from archive-page.php to single-page.php

I have archive-page.php, where my custom posts are displayed. I want to put a link on my image, <a href="" alt=""><img src="" alt=""></a>, which leads to single-page.php for that ...
0
votes
1answer
123 views

Load different single.php templates according to post layout selection

I have created a way of choosing different layouts for posts(sidebar right, sidebar left, full width). This is done through a meta box that displays radio buttons with an image for each layout type. ...
0
votes
1answer
18 views

Wordpress not using edited image

I have uploaded a picture to media library and cropped the image in wordpress editor but when selecting the edited image http://mariehelenesund.se/wp-content/uploads/2015/11/Kicki-e1447542665309.jpg ...
0
votes
1answer
38 views

how to change single post link

I have made a website for a client which involves products tab in navigation. Products are the posts that being posted in "posts". I have a front-page.php which is static. posts are displayed in ...
0
votes
1answer
83 views

permalink to single page

I have a certain post displayed and each post i click go to single page which shows more details of the post. But i have different templates for the post details which will be shown in single page. ...
0
votes
1answer
37 views

“post-name” Renders Using page.php, but “post-name-2” renders with single.php

Page One is rendering using my page.php template. Page Two, set up exactly the same as the previous one, is rendering using my single.php template. I want Page One to render using the single.php ...
0
votes
1answer
56 views

Custom Single Post Type not referring to single-post-type.php File

I've defined a Custom Post type called "Press", I'm trying to modify the Single Posts template for that Custom Type. The single posts custom file is called "single-press.php" I've tried using an if ...
0
votes
1answer
24 views

Different post into a single page

i am having a little trouble here. Well what i am exactly trying to do is post posts into different divs in my wordpress template in a single page. How am it to achieve different posts in different ...
0
votes
1answer
99 views

WP_Query shows all posts on single post pages

Looking for assistance with WP_Query. I'm learning to create WordPress themes and I am practicing by creating a real estate theme. What I am trying to do is set up a properties page (custom post type) ...
0
votes
1answer
87 views

Code to display category-specific single.php is overriding normal single.php, too

I have two different post type categories on the site I'm building at the moment - "press" and "blog". I used the following code, inserted in my child theme's functions.php file, to get the "press" ...
0
votes
1answer
237 views

Content-single.php inside my plugin

I have implemented inside my plugin this hook to change the single template for custom post type (I do not want it to be in the child theme, just in my plugin) and it works just fine. Now I want to ...
1
vote
0answers
451 views

Add Read More Tag to a post content (Single.php)

I have wordpress custom theme made from scratch including: header.php, footer.php, single.php, index.php, functions.php For Listing the blog list i used index.php with excerpt and read more link to ...
1
vote
0answers
69 views

Issue with loading mobile specific custom single page layout in mobile

Hello I am in the middle of theme development which has specific layouts for mobile, I built a custom function to detect mobile and load mobile specific layouts in mobile view ports. Here is the ...
1
vote
0answers
46 views

Issue on single.php pagination WordPress

I faced weird issue on single.php. I used previous_post_link('%link', 'Previous'); and next_post_link('%link', 'Next'); for next previous in single.php, it's working perfectly, but its work on all ...
1
vote
0answers
34 views

On single.php, fetch 2 posts created after and 2 posts created before in relation to the actual post (using menu_order)

Looking for a way to on single.php fetch and show the actual post, and then by looking on the menu_order value of that specific post (lets say the post have menu_order value 3 in this case) go and ...
1
vote
0answers
104 views

How to make the link to the category for a post go to corresponding page number in archive?

For instance, I am at http://url.com/single-post and in the post there is a link to the category that navigates to http://url.com/category/page/3/ which is the corresponding archive page that contains ...
1
vote
0answers
117 views

Adding range to wp_link_pages();

I have some very long posts, some have more than 50 pages() and when using wp_link_pages it give me 50 internal post links, clearly this isn't usable. How can I add a range to the wp_link_pages ...
1
vote
0answers
131 views

Modified loop-single-forum.php to work inside of a sidebar Widget, not working on some site pages

So I took loop-single-forum.php, copied it and renamed it, fixed it so the site is calling the copy and then removed what I did not need from it to place it in a sidebar widget. It works beautifully ...
0
votes
0answers
15 views

Having to flush_rewrite_rules() everytime I make custom post type

I keep running into this issue where every time I make a new custom post type, I have to flush_rewrite_rules() for it to have a single.php or I get 404 when I go to view the post. Anyone have an idea ...
0
votes
0answers
14 views

Assigning custom-single.php based on category

The code below looks like exactly what I need but I dont know how to update it to work for 3 custom single.php files plus the default single.php for any other posts not in one of these 3 categories ...
0
votes
0answers
19 views

Get current category for post with multiple categories (custom taxonomy)

I have created a custom taxonomy for services and a custom post type of service, there are currently 6 categories within services and each post can be assigned to multiple categories. What I would ...
0
votes
0answers
84 views

get_adjacent_post - in same term or category not working

I am building a Next and Previous Post navigation for my 'Single post' pages, inside a plugin. What I am trying to do is get the Prev/Next post within the same category of a Custom Post Type. So I ...
0
votes
0answers
14 views

Error 500 in single post page after deactivating Wp Cache Plugin

Everything was fine in my blog, until I deactivated the Wp Cache plugin and it suddenly stopped loading every single post pages. It simply appears Error 500 and do not load anything at all, as you can ...
0
votes
0answers
27 views

Custom post type single page - always show latest post

I have created custom post type 'products' and template: 'single-products.php' In this template file I have a code: <?php the_post();?> <h1><?php the_title();?></h1> <div ...
0
votes
0answers
52 views

Related products Woo-commerce

I am developing an custom non Woo Ecommerce site into it .All I require is to move related products information to my side bar. Right now I have random products on my single.php. The sidebar named ...
0
votes
0answers
24 views

Start directly with first image of gallery

I would like to link users directly into the first image of my gallery. When the user clicks on a new post on my homepage, I want them to see the attachment.php right away, without going to the ...
0
votes
0answers
33 views

passing category name from category.php to single.php

It's the first time I used WP. I just use a small portion of it, because I already had my website ready. So the only section that uses WP is the blog section. I finally was able to implement it has ...
0
votes
0answers
15 views

how to create Multiple pages after one another in single page. other than home page

I am using zerif pro theme for my site . I need pages displayed one after the other , in other than home page. Please help and explain in detail.
0
votes
0answers
18 views

Is it better to set social media sharer in entry-footer.php or comments.php in Wordpress blog?

I'm now deciding where should I put social media sharers. Currently, I'm now putting sharers code in entry-footer.php. But is it more semantic to put sharers in entry-footer.php, in the bottom of ...
0
votes
0answers
37 views

2 different templates for 1 query

I have a working query with some custom meta fields (among others ACF Gallery field) which displays news on "News" page. I have also second page named "Gallery" which is quering posts by gallery ...
0
votes
0answers
84 views

Show Post title and featured image outside of the box

I'm trying to work out my idea to show post featured image and post title outside of the post content. Let me explain better. I'm using underscore framework. There are three files there. single.php, ...
0
votes
0answers
18 views

Grabbing Custom Single Post Template displays WSOD

I'm trying to use a custom Single Post Template & call it via my single.php (It wasn't drawing from single-press.php otherwise) My main goal is to have the Custom Single Posts not display the ...
0
votes
0answers
28 views

does it need any special functions to write in function.php?

does it need any special functions to write in function.php of template for single-{post_type}.php? I created a custom theme , but it does not move the single-{post_type.php}, my page is ...
0
votes
0answers
57 views

Disable single post page in wordpress

I hate how when you click on a frontpage post (I have mine layed out in columns on my frontpage), it goes to the single view of the post. I would like for it to go to the blog page but scroll down to ...
0
votes
0answers
193 views

Using get_template_part() to modify single.php for a custom post type

I have a custom post type plugin called shows that has custom meta such as host, time, length, etc. I want to make it theme independent and require minimum coding for it to work across a lot of ...
0
votes
0answers
166 views

Hide Certain Tags on Single Post Page

I'm trying to hide certain tags from single posts pages. I've googled and found 2 codes but both are hiding the whole post page. I'm using a theme that needs using 2 tags ticker and slider to show ...
0
votes
0answers
100 views

Page Templates Used in Custom Post Type

The same question was asked here with no real response. They claim it's not possible but I have used plugins that accomplish this. In WordPress I am having a problem figuring out how to use the ...
0
votes
0answers
33 views

Single page of CPT

I'm trying to create a single page of a CPT. My cpt: <?php // CONVENZIONI CPT + TAXONOMY function cpt_convenzioni() { $labels = array( 'name' => _x( 'Convenzioni', ...
0
votes
0answers
38 views

How to test a WordPress plugin on a single post?

I would like to test a plugin on a single post, where the ID = 12546. I tried is_single('12546') in plugin.php and $post->ID with global $post;. Any suggestions to get this working.
0
votes
0answers
139 views

Custom post type single display is ommited

I've created a custom post type: tutorials using generatewp.com generator and registered it with register_post_type(). I'm querying the list of tutorials in a custom page template like that: ...
0
votes
0answers
67 views

Get active term on single (CPT) page

I know similar questions have been asked here but I feel my case is slightly different. I need to get the active current term (object) on a CPT single page. However, the single post can have ...
0
votes
0answers
94 views

Permalinks not working for post IDs as slug

I inherited a site that has a lot of posts without a title, thus the permalink defaults to the post ID, with pretty permalinks turned on. IE - http://mysite.com/1200 When the permalinks are reset to ...
0
votes
0answers
73 views

image class removed in excerpt

I have inline images in my post content that have classes. the classes are available as I go to single page like this: <img src="the_cource.jpg" class="myclass"> , but are removed as I look ...
0
votes
0answers
109 views

how to load custom single.php?

Hi I have a blog where the categories are news, events and inspiration. These categories are selected using radio buttons on acf. I want to load news on single-news.php while events on ...
0
votes
0answers
936 views

If in_category not working for multiple single.php pages

I searched far and wide (on here & Google), reading about how to have multiple single.php pages for different categories of posts. The consensus was to do something like this: <?php /* ...
0
votes
0answers
148 views

different single.php for different page templates

I have 4 page templates with same query. Is it possible to write conditional statement? If I go to single post view (single.php) from page template 1 (page-main.php) display something (for example ...
0
votes
0answers
111 views

Modify / Rewrite single template url structure

Is it possible to add the post category name to the the WordPress single template url structure if i am not using category pages to build the site menu? from www.domain.com/single-post-title to ...
0
votes
0answers
102 views

Single.php loading fully on localhost but not on server

The title explains the issue. I did my best to find reason behind such dysfunctionning. Can you please tell me what can be the causes of such issue? Any techniques to investigate the problem are ...
0
votes
0answers
66 views

Wordpress doesn't generate rel=prev & rel=next

I am developing a Wordpress theme from scratch and I've been using previous_post_link() & next_post_link() quite often and never had any trouble using them. Until now.. So what I'm trying to ...