Skip Navigation

[Resolved] The view I made for my post type works. But single content template does not.

This support ticket is created 2 years, 5 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
- 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 -
- 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 -

Supporter timezone: Asia/Kolkata (GMT+05:30)

This topic contains 3 replies, has 2 voices.

Last updated by Elsie 2 years, 5 months ago.

Assisted by: Minesh.

Author
Posts
#2379035

Tell us what you are trying to do? I'm trying to make a single content template for my post type (Rides & Tours)

Is there any documentation that you are following? Yes, I created it as you're supposed to. But when I look at a single instance of my post type, all I see is the "body" of the post.

Is there a similar example that we can see? hidden link (PW: bf)

What is the link to your site? hidden link (PW: bf)

#2379049

More info... The page is pulling the single.php file. Here's what that looks like, in case it provides any info:

<?php defined( 'ABSPATH' ) OR die( 'This script cannot be accessed directly.' );

/**
* The template for displaying all single posts
*
* Do not overload this file directly. Instead have a look at templates/single.php file in us-core plugin folder:
* you should find all the needed hooks there.
*/

if ( function_exists( 'us_load_template' ) ) {

us_load_template( 'templates/single' );

} else {
get_header();
?>
<main id="page-content" class="l-main">
<?php
while ( have_posts() ) {
the_post();

get_template_part( 'content' );
}
?>
</main>
<?php
get_footer();
}

#2379277

Minesh
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

Hello. Thank you for contacting the Toolset support.

I will require to check whats going wrong with your setup. Can you please share details what content template you created for what post type and share admin access details.

*** Please make a FULL BACKUP of your database and website.***
I would also eventually need to request temporary access (WP-Admin) to your site. Preferably to a test site where the problem has been replicated if possible in order to be of better help and check if some configurations might need to be changed.

I have set the next reply to private which means only you and I have access to it.

#2379553

My issue is resolved now. Thank you!

I edited that single.php file to remove the if/then statement.