psnepsts
Forum Replies Created
-
2.1.9 on WP 4.1
Not multisite. I did click the link, but once this ‘-view.png’ is requested, the plugin deactivates and pops this error into the top of all admin area pages.
I can’t find any such image in the plugin directories, but it’s clear here that it’s being requested.
Forum: Themes and Templates
In reply to: Query by Tag first, if not present, return all from a post_typeThis log is from yesterday, the errors to do with ASC have been repaired, as have the bloginfo(‘siteurl’) ones. The others seem to indicate wp-includes/functions.php as having some deprecated code present.
—
Upon further digging, it seems this problem is related to ‘posts_per_page’.
This sidebar is supposed to display posts in the ‘events’ custom post type whose tag slug matches the page title’s slug. If none match that criteria, go ahead and pull all events. There’s some other fun stuff in there too on the live site, like ordering them by event date, not showing them if they’re in the past… that kinda thing.
For some reason, though, adding ‘posts_per_page’ => 8 (or any number) to the sub-query produces no results despite empirical tests that events in fact do exist that match the query. The idea here is to limit the number of events shown to some number that the design likes, but that is informative to a visitor. 8 works in this case.
Removing ‘posts_per_page’ altogether seems to work – but imperfectly. I should now be defaulting to the number of posts specified in Settings/Reading (which I have set to 8). On the following page, only 6 events are being output, though I know for certain there are more events that should be displaying here (by looking at the Events listing):
https://kawarthasnorthumberland.ca/what-to-do/arts-culture-heritage/Surely there’s something wonky here. Why would including ‘posts_per_page’ produce such unpredictable results? And why would the Settings/Reading setting not be governing the number of posts appearing?
Again – this seems to be working just fine in the test environment.
Forum: Themes and Templates
In reply to: Query by Tag first, if not present, return all from a post_typeIt’s called error.log and it’s a report I pulled from the server’s control panel. When I put the site into DEBUG mode, the errors match, however.
Forum: Themes and Templates
In reply to: Query by Tag first, if not present, return all from a post_typeMy error log shows some deprecated stuff coming from the wp-includes/functions.php and other seemingly non-related things.
Forum: Themes and Templates
In reply to: Query by Tag first, if not present, return all from a post_typeI tried debugging but didn’t see anything that might be related. Haven’t delved into error logging.
On a whim, I just tried removing the ‘tag’ info from the first query (essentially making it the exact same as the 2nd query) and now the sidebar is not drawing records at all! Any idea why that would be?
Forum: Plugins
In reply to: [Posts 2 Posts] Defining order of outputAh – blessed goodness. Many thanks. Great plugin.
Forum: Plugins
In reply to: [Posts 2 Posts] [Plugin: Posts 2 Posts] Problem upgrading from 1.1.5 to 1.1.6I should add, that when I re-added a few, some of my template pages started displaying as expected.
Forum: Plugins
In reply to: [Posts 2 Posts] [Plugin: Posts 2 Posts] Problem upgrading from 1.1.5 to 1.1.6There are no Venues or Troupes in the meta boxes of the add/edit pages. It’s as if I did not associate them at all.
Forum: Plugins
In reply to: [Posts 2 Posts] [Plugin: Posts 2 Posts] Problem upgrading from 1.1.5 to 1.1.6All connected posts previously entered have been disassociated from one another. In my example, an entry for a post_type of ‘tscf-show’ would be connected to a number of ‘tscf-troupes’ entries, and one ‘venues’ entry. This update has resulted in the connections I’d made in the past no longer being present.
Forum: Plugins
In reply to: [Posts 2 Posts] [Plugin: Posts 2 Posts] Problem upgrading from 1.1.5 to 1.1.6Well… no wonder I wasn’t getting my pages as I had thought they should be. All of my existing connections have been blown out.
Forum: Plugins
In reply to: [Posts 2 Posts] [Plugin: Posts 2 Posts] Problem upgrading from 1.1.5 to 1.1.6Also, I presume that:
p2p_list_posts( $post->actors );
simply outputs a list of links to associated posts.
In the example I am using above, I used to be able to loop over the results and access the post_meta for each to output, for example, a link to a map that is generated using a custom field for the venue’s address.
Forum: Plugins
In reply to: [Posts 2 Posts] [Plugin: Posts 2 Posts] Problem upgrading from 1.1.5 to 1.1.6In this case, is ‘actors’ the name of the post_type?
p2p_type( 'movies_to_actors' )->each_connected( $my_query, array(), 'actors' );
My issue here is identical to that outlined here:
https://www.ads-software.com/support/topic/plugin-posts-2-posts-problem-upgrading-from-115-to-116?replies=7#post-2675131Best to flip over to that thread for a backgrounder.
Forum: Plugins
In reply to: [Posts 2 Posts] [Plugin: Posts 2 Posts] Problem upgrading from 1.1.5 to 1.1.6I have similar woes with the 1.1.6 upgrade. In my case, I have nested loops that draw connected information from the $post->ID (as opposed to get_queried_object_id()). I have 3 Custom Post Types to to run an event system for a comedy festival: tscf-troupes, tscf-shows, and venues. Each show can have multiple troupes attached to it, but only one venue. Each troupe can be attached to multiple shows.
Here’s what my template’s ‘single’ looks like for a particular “Troupe:”
The first query seeks to get all ‘tscf-shows’ that the current ‘tscf-troupe’ is attached to and display each.
The second query is a sub-query that seeks to get the ‘venues’ that is attached to each show that is returned in the first query, and output its address.
The third query, also a sub-query, seeks to find the name of each ‘tscf-troupe’ that is featured on each show from the first query, and output a link to that troupe’s page. (The current troupe would also output in this list with a link to the current page).
Now – prior to the 1.1.6 upgrade, these all worked smoothly. Should I downgrade to 1.1.5? If so, I’m committing myself to sticking with that version and I’m not sure that’s the best idea.
Any ideas here would be very much appreciated.