[Resolved] Blocks view not displaying data at Front End

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.

This topic contains 27 replies, has 2 voices.

Last updated by markP-18 3 months, 1 week ago.

Assigned support staff: Nigel.

Author
Posts
#1559163

I am trying to:
Display a list of entries of a custom Post Type (Volunteers) on a Page in the front end.
Link to a page where the issue can be seen:
hidden link
I expected to see:
A list of 'volunteers' (I have more than 20 such 'Volunteer' items in the database which I can view in the back end).
Instead, I got:
Nothing.

The back end editor, when editing the page in question shows one row of real data taken from the database, and if I change the 'sort by' I will see a different sample row of real data.
I've tried putting fields into a Container in the view loop.
I've tried making the view paginated and none paginated.
I've created new views, so I'm not just editing a known problem view.

The archive page shows this (now that I've made a template for it):
hidden link
Here we can see the expected number of 'pages' for the pagination, but there are no actual rows of data.

This is for our local COVID-19 support system.

#1559729

Nigel
Supporter

Languages: English (English ) Spanish (Español )

Timezone: Europe/London (GMT+01:00)

Hi Mark

It's hard for me to comment without seeing the backend, and the quickest way for me to help would probably be if you let me have access to it, if that's okay.

Let me mark your next reply as private so that I can get log-in credentials from you—you may want to create a temporary admin user for me to use that you can later delete. And be sure to have a current backup of your site.

#1559807

I should add. The standard WordPress Archive page for 'Volunteers' worked fine. It showed the Post Title of each post.

#1560249

Nigel
Supporter

Languages: English (English ) Spanish (Español )

Timezone: Europe/London (GMT+01:00)

Could I get access to your site?

#1560253

Yes. Go ahead. Use the information that I provided in the earlier secure reply.
Thanks. 🙂

#1560255

Nigel
Supporter

Languages: English (English ) Spanish (Español )

Timezone: Europe/London (GMT+01:00)

Not sure what went wrong but there is no such information, could you please try again?

#1560281

Hopefully you've just received the private info.

#1560305

Nigel
Supporter

Languages: English (English ) Spanish (Español )

Timezone: Europe/London (GMT+01:00)

Got it, thanks.

Looking.

#1560331

Nigel
Supporter

Languages: English (English ) Spanish (Español )

Timezone: Europe/London (GMT+01:00)

You only have one published volunteer (which shows in the View). The others are all pending. They won't show until they are published.

#1560333

They were published. This morning I unpublished them. I'll publish a couple more now to add to the one that should be disdplaying.

#1560373

Nigel
Supporter

Languages: English (English ) Spanish (Español )

Timezone: Europe/London (GMT+01:00)

I can't use the normal debugging settings because the content is private and I don't want to change that on your live site.

I tried to add a backup plugin to take a copy so I could test it locally, but I can't add new plugins.

Could you provide me with a site copy?

The easiest way would be for you to use the All in One WP Migration plugin to generate a backup, it's very simple, and then share the archive file with me here.

You can link to the archive as it is stored on your server, or upload it somewhere like dropbox and share that URL.

Any URL you paste here will be private.

#1560393

Here we go:
hidden link
It's already upsynced to dropbox.

#1561357

Nigel
Supporter

Languages: English (English ) Spanish (Español )

Timezone: Europe/London (GMT+01:00)

Thanks for that.

I installed the site locally, which appears to be working without problems.

I had turned on the Views debug mode on your site to help examine the issue, but it doesn't return the expected debugging information (it does on the local copy).

So the problem appears server-related.

On your dashboard there is a WordPress notice that a PHP upgrade is required, I suggest you comply with that.

If you still see problems creating views of volunteers then I suggest you check your PHP logs for errors or notices.

If you haven't already, turn on the debug log by editing your wp-config.php file and change the line with WP_DEBUG like so:

define('WP_DEBUG', true);
define('WP_DEBUG_LOG', true);
define('WP_DEBUG_DISPLAY', false);
define('WP_DISABLE_FATAL_ERROR_HANDLER',true);

That will create a debug.log file in your /wp-content/ directory which you can examine in any text editor. Try visiting the same page where you observe the problem and then inspect the log. If you don't find the debug.log file it means it didn't generate any warnings or errors.

Let me know if that reveals anything.

#1561363

Hi Nigel,
I've just gone to a page with the problem:
hidden link

and it has logged:
[24-Mar-2020 11:25:45 UTC] PHP Notice: Trying to get property of non-object in /home/chardcovhelp/public_html/wp-content/plugins/toolset-blocks/embedded/inc/wpv.class.php on line 2201

My understanding is that Toolset is compatible with the version of PHP that I have as submitted in my "toolset debug information":
"PHPVersion":"5.6.40"

#1561381

Nigel
Supporter

Languages: English (English ) Spanish (Español )

Timezone: Europe/London (GMT+01:00)

Let me set up a server with PHP 5.6 and I'll see if I can reproduce the error with that.

I'll get back to you.