dapehe
Forum Replies Created
-
Hello
I have been looking at the plugin code and the only function that gives a list of series ordered by date is get_series_ordered, but you cannot paginate the results with this function. So I have decided to modify it and include it in functions.php. I leave it here, in case it is useful for you./** * Get an ordered list of series. * * @param args array */ function get_series_ordered_custom($args = '') { global $wpdb; $post_types = apply_filters('orgseries_posttype_support', array('post')); $defaults = array('orderby' => 'term_id', 'order' => 'DESC', 'postTypes' => $post_types, 'hide_empty' => TRUE); $args = wp_parse_args($args, $defaults); extract($args, EXTR_SKIP); $orderby = strtolower($orderby); if ('post_date' == $orderby) { if ('ASC' == $order) $_orderby = 'min(tp.post_date)'; else $_orderby = 'max(tp.post_date)'; } else if ('post_modified' == $orderby) { if ('ASC' == $order) $_orderby = 'min(tp.post_modified)'; else $_orderby = 'max(tp.post_modified)'; } else if ('name' == $orderby) $_orderby = 't.name'; else if ('slug' == $orderby) $_orderby = 't.slug'; elseif (empty($orderby) || 'id' == $orderby || 'term_id' == $orderby) $_orderby = 't.term_id'; elseif ('count' == $orderby) $_orderby = 'tt.count'; elseif ('rand' == $orderby) $_orderby = 'RAND()'; $having = ''; if ($hide_empty) { $having = 'HAVING count(tp.id) > 0 '; } $postTypes = "'" . implode("','", $postTypes) . "'"; $query = "SELECT t.term_id, t.name, t.slug, tt.count FROM $wpdb->terms AS t INNER JOIN $wpdb->term_taxonomy AS tt ON tt.term_id = t.term_id LEFT OUTER JOIN $wpdb->term_relationships AS tr ON tr.term_taxonomy_id = tt.term_taxonomy_id LEFT OUTER JOIN $wpdb->posts AS tp ON tp.ID = tr.object_id and tp.post_status IN ( 'publish', 'private' ) and tp.post_type in ($postTypes) WHERE tt.taxonomy = '" . ppseries_get_series_slug() . "' GROUP BY t.term_id, t.name, t.slug $having ORDER BY $_orderby $order LIMIT $number OFFSET $offset"; $series = $wpdb->get_results($query); return $series; }
Thank you very much for your help
Unfortunately, I will have to look for other options ??Mateusz
Activating Development Mode to On, the message disappears ??
I think the problem is Cloudflare
Gracias ??Hi
No, persist ??Hi
I have the standard, default settings.Caching > Configuration:
– Caching Level: Standard
– Browser Cache TTL: 1 year
– CSAM Scanning Tool: Standard, I don’t even know what it’s for ??
– Crawler Hints: Off
– Always Online: Off
– Development Mode: OffCaching > Cache Rules: Empty, no rules
Caching > Tiered Cache:
– Argo Tiered Cache: Off- This reply was modified 2 years, 2 months ago by dapehe.
Hi Mateusz
—-.com
Thxs!- This reply was modified 2 years, 2 months ago by dapehe.
Hi Mateusz
Thanks for your reply.
No, i haven`t custom rules in Cloudflare.
Thanks again
Hi @jenhooks
Thank you for your reply.
I have developed my own multi-language system and I would not like to switch to WPML and Polylang.
I have submitted a support ticket ??
Thanks
Hello
Thank you very much for your reply.
Actually, my site is connected to a single URL (domain.com). The issue is that my site is multi-language and I use subdomains to distinguish the different languages (en.domain.com, ru.domain.com, es.domain.co, etc..), but in Jetpack configuration the url that is indicated is https://domain.com.
I’m afraid that Jetpack is not prepared for these situations, which are quite common in multi-language sites ??
It is really shame
Hello
I recently contributed to the Spanish translation of the plugin, but it’s not available yet.When will we be able to enjoy the plugin in Spanish?
Thank you
Hi
Great!!
ThanksHi
Any updates on this topic?
ThanksHi
Any updates on this topic?
Thanks