Title: Chris's Replies | WordPress.org

---

# Chris

  [  ](https://wordpress.org/support/users/moargh/)

 *   [Profile](https://wordpress.org/support/users/moargh/)
 *   [Topics Started](https://wordpress.org/support/users/moargh/topics/)
 *   [Replies Created](https://wordpress.org/support/users/moargh/replies/)
 *   [Reviews Written](https://wordpress.org/support/users/moargh/reviews/)
 *   [Topics Replied To](https://wordpress.org/support/users/moargh/replied-to/)
 *   [Engagements](https://wordpress.org/support/users/moargh/engagements/)
 *   [Favorites](https://wordpress.org/support/users/moargh/favorites/)

 Search replies:

## Forum Replies Created

Viewing 15 replies - 1 through 15 (of 30 total)

1 [2](https://wordpress.org/support/users/moargh/replies/page/2/?output_format=md)
[→](https://wordpress.org/support/users/moargh/replies/page/2/?output_format=md)

 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Shop as Client for WooCommerce - Manual, Phone & Email Orders] Order history: Filter by “order handler”](https://wordpress.org/support/topic/order-history-filter-by-order-handler/)
 *  Thread Starter [Chris](https://wordpress.org/support/users/moargh/)
 * (@moargh)
 * [3 years, 11 months ago](https://wordpress.org/support/topic/order-history-filter-by-order-handler/#post-16096528)
 * Great – many, many thanks for that!
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Shop as Client for WooCommerce - Manual, Phone & Email Orders] Order history: Filter by “order handler”](https://wordpress.org/support/topic/order-history-filter-by-order-handler/)
 *  Thread Starter [Chris](https://wordpress.org/support/users/moargh/)
 * (@moargh)
 * [3 years, 11 months ago](https://wordpress.org/support/topic/order-history-filter-by-order-handler/#post-16096414)
 * Oh wow, that’s quite a coincidence – perfect!
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Ajax Load More – Infinite Scroll, Load More, & Lazy Load] Ajax Load More with nested meta_query](https://wordpress.org/support/topic/ajax-load-more-with-nested-meta_query/)
 *  [Chris](https://wordpress.org/support/users/moargh/)
 * (@moargh)
 * [5 years, 8 months ago](https://wordpress.org/support/topic/ajax-load-more-with-nested-meta_query/#post-13858801)
 * Hi Darren,
 * Is it possible to write the query (or in general a nested meta query) in a shortcode
   like
 * `echo do_shortcode( '[ajax_load_more … ]' );`
 * Thanks!
    -  This reply was modified 5 years, 8 months ago by [Chris](https://wordpress.org/support/users/moargh/).
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Add Polylang support for Customizer] Wrong Permalink on translated Custom Post Type name](https://wordpress.org/support/topic/wrong-permalink-on-translated-custom-post-type-name/)
 *  [Chris](https://wordpress.org/support/users/moargh/)
 * (@moargh)
 * [6 years, 3 months ago](https://wordpress.org/support/topic/wrong-permalink-on-translated-custom-post-type-name/#post-12965178)
 * Hi Richard,
 * I just tried the update but unfortunately it does not work for me.
    See screencast:
   [https://www.dropbox.com/s/1s7gotwlyelgfg8/PolylangCustomizer.mp4?dl=0](https://www.dropbox.com/s/1s7gotwlyelgfg8/PolylangCustomizer.mp4?dl=0)
 * Plugin versions:
    Add Polylang support for Customizer: 1.1.3 Polylang Pro: 2.7.3
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Add Polylang support for Customizer] Wrong Permalink on translated Custom Post Type name](https://wordpress.org/support/topic/wrong-permalink-on-translated-custom-post-type-name/)
 *  [Chris](https://wordpress.org/support/users/moargh/)
 * (@moargh)
 * [6 years, 4 months ago](https://wordpress.org/support/topic/wrong-permalink-on-translated-custom-post-type-name/#post-12832992)
 * I just ran into the same problem — thanks for fixing it!
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Relevanssi - A Better Search] Show/Hide protected content based on user roles](https://wordpress.org/support/topic/show-hide-protected-content-based-on-user-roles/)
 *  Thread Starter [Chris](https://wordpress.org/support/users/moargh/)
 * (@moargh)
 * [6 years, 5 months ago](https://wordpress.org/support/topic/show-hide-protected-content-based-on-user-roles/#post-12620704)
 * Thanks a lot for outlining this.
 * I just read a bit through the `relevanssi_match` hook ([https://www.relevanssi.com/knowledge-base/relevanssi-match/](https://www.relevanssi.com/knowledge-base/relevanssi-match/)
   and [https://www.relevanssi.com/knowledge-base/using-customfield_detail/](https://www.relevanssi.com/knowledge-base/using-customfield_detail/))
   and I was wondering if it would be possible when the restricted content would
   be in a certain custom field (ACF field), for example `premium-user-content`?
 *     ```
       add_filter('relevanssi_match', 'cfdetail');
   
       function cfdetail($match) {
       	global $customfield_data;
       	$customfield_data[$match->doc] = $match->customfield_detail;
       	return $match;
       }
   
       add_filter('relevanssi_match', 'rlv_cf_boost');
   
       function rlv_cf_boost( $match ) {
   
       	$user   = wp_get_current_user();
       	$detail = json_decode( $match->customfield_detail );
   
       	if (!empty($detail)) {
       		if (isset($detail['premium-user-content'])) {
   
       			if ( ! in_array( 'premium-member', $user->roles[0], true ) ) {
       				$match->weight = 0;
       			}
   
       		}
   
       	}
   
       	return $match;
   
       }
       ```
   
 * Would that work with Relevanssi premium?
    I am very thankful for your time!
    -  This reply was modified 6 years, 5 months ago by [Chris](https://wordpress.org/support/users/moargh/).
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Relevanssi - A Better Search] Show/Hide protected content based on user roles](https://wordpress.org/support/topic/show-hide-protected-content-based-on-user-roles/)
 *  Thread Starter [Chris](https://wordpress.org/support/users/moargh/)
 * (@moargh)
 * [6 years, 5 months ago](https://wordpress.org/support/topic/show-hide-protected-content-based-on-user-roles/#post-12617815)
 * Hi Mikko,
 * Many thanks for getting back to me so quickly and for your hint.
 * I made progress but there’s one thing that I don’t figure out …
    So this is my
   current filter hook:
 *     ```
       add_filter( 'relevanssi_post_ok', 'rlv_allowed_user', 11, 2 );
   
       function rlv_allowed_user( $show, $post_id ) {
   
       	$user                = wp_get_current_user();
       	$allowed_all         = array( 'member', 'board' );
       	$allowed_pemium_only = array( 'premium-member' );
   
       	if ( in_array( 'acf/restricted', $block_names ) ) { 
   
       		// Do not show to non-premium users
       		if ( !( in_array( 'premium-member', $user->roles[0] ) ) ) {
       			$show = false;
       		}
   
       	}
   
       	return $show;
   
       }
       ```
   
 * It says that if a user does not have the role “premium-member” no search results
   will be displayed. So that’s obviously not what I want. 😀
 * What I need is another a condition to check if the found result is limited to
   only be viewed by premium users. But I don’t know how to do that. It’s not that
   whole posts would not be visible to non-premium users but it’s just some snippets
   in these posts that are wrapped in `if ( !( in_array( 'premium-member', $user-
   >roles[0] ) ) ) {`.
 * Do you have another hint for me?
    Thanks a lot for your effort!
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Contact Form 7] Multiple forms with same ID on same page](https://wordpress.org/support/topic/multiple-forms-with-same-id-on-same-page/)
 *  Thread Starter [Chris](https://wordpress.org/support/users/moargh/)
 * (@moargh)
 * [6 years, 10 months ago](https://wordpress.org/support/topic/multiple-forms-with-same-id-on-same-page/#post-12162699)
 * Hi,
 * Thank you for clearing things up.
 * I will ask the question in that forum but I would appreciate if you could have
   a look at the website on which the problem occurs:
 * [https://bit.ly/2pFchRh](https://bit.ly/2pFchRh)
 * The list is expandable and each list item has a contact form. The first five 
   work well but when the six’s is loaded none of the forms works anymore.
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Contact Form 7] Multiple forms with same ID on same page](https://wordpress.org/support/topic/multiple-forms-with-same-id-on-same-page/)
 *  Thread Starter [Chris](https://wordpress.org/support/users/moargh/)
 * (@moargh)
 * [6 years, 10 months ago](https://wordpress.org/support/topic/multiple-forms-with-same-id-on-same-page/#post-12162560)
 * Thanks for getting back to me so quickly.
 * Unfortunately I currently don’t have a public link for testing but I will provide
   one asap.
 * I just found out that multiple forms even with the same ID actually work – sorry
   for that. The problem is when using WPCF7 with the Ajax Load More plugin (ALM,
   [https://connekthq.com/plugins/ajax-load-more/](https://connekthq.com/plugins/ajax-load-more/)).
 * The ID of the form which is loaded via ALM is not unique anymore but the same
   as the first one (in my case `wpcf7-f5-o1`). This causes the problem, doesn’t
   it?
 * Do you have an idea how to maintain the ID logic (`wpcf7-f5-o1`, `wpcf7-f5-o2`,`
   wpcf7-f5-o3`, …) even when forms are loaded via ALM?
    -  This reply was modified 6 years, 10 months ago by [Chris](https://wordpress.org/support/users/moargh/).
    -  This reply was modified 6 years, 10 months ago by [Chris](https://wordpress.org/support/users/moargh/).
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Contact Form 7] Is multiple forms on the same page supported?](https://wordpress.org/support/topic/is-multiple-forms-on-the-same-page-supported/)
 *  [Chris](https://wordpress.org/support/users/moargh/)
 * (@moargh)
 * [6 years, 10 months ago](https://wordpress.org/support/topic/is-multiple-forms-on-the-same-page-supported/#post-12162002)
 * Hey [@dalefoxwiz](https://wordpress.org/support/users/dalefoxwiz/),
 * I ran into the same issue. Is it possible that you share your solution?
 * Many thanks,
    Chris
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Germanized for WooCommerce] »Kauf abschließen«-Button – Umbenennung funktioniert nicht mehr](https://wordpress.org/support/topic/kauf-abschliesen-button-umbenennung-funktioniert-nicht-mehr/)
 *  Thread Starter [Chris](https://wordpress.org/support/users/moargh/)
 * (@moargh)
 * [7 years, 10 months ago](https://wordpress.org/support/topic/kauf-abschliesen-button-umbenennung-funktioniert-nicht-mehr/#post-10863842)
 * Es ist das offizielle Plugin: [https://docs.woocommerce.com/document/paypal-express-checkout/](https://docs.woocommerce.com/document/paypal-express-checkout/)
 * Ich finde es auch merkwürdig – zumal es nach dem Deaktivieren und wieder Neuaktivieren
   wieder alles in Ordnung ist.
 * Danke fürs Nachforschen.
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Germanized for WooCommerce] »Kauf abschließen«-Button – Umbenennung funktioniert nicht mehr](https://wordpress.org/support/topic/kauf-abschliesen-button-umbenennung-funktioniert-nicht-mehr/)
 *  Thread Starter [Chris](https://wordpress.org/support/users/moargh/)
 * (@moargh)
 * [7 years, 10 months ago](https://wordpress.org/support/topic/kauf-abschliesen-button-umbenennung-funktioniert-nicht-mehr/#post-10863270)
 * Vielen Dank für den Hinweis – es lag an dem Plugin »WooCommerce PayPal Checkout
   Gateway«. Als ich deaktiviert habe, griff auch wieder der Button-Text aus WooCommerce
   Germanized. Trotz der Reaktivierung des PayPal-Plugins ist der Text weiterhin
   richtig.
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[DHL Shipping Germany for WooCommerce] Label pdf cannot be downloaded (not generated)](https://wordpress.org/support/topic/label-pdf-cannot-be-downloaded-not-generated/)
 *  Thread Starter [Chris](https://wordpress.org/support/users/moargh/)
 * (@moargh)
 * [7 years, 11 months ago](https://wordpress.org/support/topic/label-pdf-cannot-be-downloaded-not-generated/#post-10757454)
 * Works perfectly again—thanks for the fix!
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[DHL Shipping Germany for WooCommerce] Label pdf cannot be downloaded (not generated)](https://wordpress.org/support/topic/label-pdf-cannot-be-downloaded-not-generated/)
 *  Thread Starter [Chris](https://wordpress.org/support/users/moargh/)
 * (@moargh)
 * [8 years ago](https://wordpress.org/support/topic/label-pdf-cannot-be-downloaded-not-generated/#post-10694460)
 * After refreshing the permalinks there’s no effect.
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[DHL Shipping Germany for WooCommerce] Sender’s address – Letter in street number is stripped out?](https://wordpress.org/support/topic/senders-address-letter-in-street-number-is-stripped-out/)
 *  Thread Starter [Chris](https://wordpress.org/support/users/moargh/)
 * (@moargh)
 * [8 years ago](https://wordpress.org/support/topic/senders-address-letter-in-street-number-is-stripped-out/#post-10693733)
 * Thanks for the quick fix — it works!

Viewing 15 replies - 1 through 15 (of 30 total)

1 [2](https://wordpress.org/support/users/moargh/replies/page/2/?output_format=md)
[→](https://wordpress.org/support/users/moargh/replies/page/2/?output_format=md)