Inquiry menu title hook

We're shifting our Forum based support to a more dedicated support system!

We'll be closing our Forum support from 10th June, 2020 and move to Email Support assistance.

  • If you are a WCFM premium add-ons user, contact us- here
  • Want to know more before buying our add-ons? Send Pre sale queries- here
  • If you are a WCFM free user, please open a support ticket at WordPress.org
  • For WCFM App related queries, reach us- here
From now the forum will be read-only!

Viewing 9 reply threads
  • Author
    Posts
    • #31507
      fabeluna
      Participant

      Hello,
      I have a custom menu added to the content of the my-account woocommerce page. If I load the new my-accoount inquiry endpoint, all the menu titles of my custom menu are changed to “Inquiries” (See screenshot). I had a look at your code and I think it’s up to the “the_title” hook, located in the file “class-wcfm-enquiry.php” at line 53 and 282. It would be grateful if you could fix this in next update?
      Thanks,
      Leni

      Attachments:
      You must be logged in to view attached files.
    • #31510
      WCFM Forum
      Keymaster

      Hi,

      That’s something impossible, please check this – https://wclovers.com/wp-content/uploads/2017/11/wcfm_enquiry_myaccount.png
      My Account from my system.

      You may even check at our demo as well – http://wcfmmp.wcfmdemos.com/my-account/

      Can you please disable your custom code once and check this?
      May you have missed something and that creates the mess.

      Thank You

    • #31516
      fabeluna
      Participant

      Hello,
      thanks for quick reply, great support!
      The problem is only visible, if there is any other content element on the woocommerce my-account page, that uses the wordpress function the_title().. When I remove my custom menu from the my account page, everything works fine. I don’t know if it is not allowed or recommended to use another content element besides the woocommerce my account shortcode at the my account page?
      Thanks,
      Leni

    • #31557
      WCFM Forum
      Keymaster

      Hi,

      You are welcome πŸ™‚

      When I remove my custom menu from the my account page, everything works fine. I don’t know if it is not allowed or recommended to use another content” – you may off course use that but your code should be like this –

      $is_endpoint = isset( $wp_query->query_vars['inquiry'] );
      		
      			if ( $is_endpoint && ! is_admin() && is_main_query() && in_the_loop() && is_account_page() ) {
      				// New page title.
      				$title = __( 'Inquiries', 'wc-frontend-manager' );
      			}

      “$is_endpoint” checking is very important here.

      Thank You

    • #31566
      fabeluna
      Participant

      Hello,
      thanks for the code.
      I Think you have misunderstood or I may not have expressed myself very well. See attached some screenshots for the purposes of illustration. On my Woocommerce account page I have placed the visual composer “dynamic_sidebar” element in addition to the “woocommerce_my_account” element. This sidebar contains the wordpress menu widget(WP_Nav_Menu_Widget) – I don’t use any other custom code by myself.
      Thanks,
      Leonie

      Attachments:
      You must be logged in to view attached files.
    • #31602
      WCFM Forum
      Keymaster

      HI,

      That’s really strange!
      I have even show you the code using which we are setting menu title.

      Anyway, we will add some more restriction on this and hope you will not have this issue anymore.

      Thank You

    • #31621
      fabeluna
      Participant

      Hello,
      Perfect, many thanks for this! πŸ™‚
      Leni

    • #31728
      WCFM Forum
      Keymaster

      Hi,

      WCFM new version is there, please update yours and take a look.

      Thank You

    • #31731
      fabeluna
      Participant

      Hello,
      it works like a charm! Thank you so much for the quick update, awesome!
      Leni

      Attachments:
      You must be logged in to view attached files.
    • #31751
      WCFM Forum
      Keymaster

      You are welcome πŸ™‚

      If you get a chance then please leave for me – https://wordpress.org/support/plugin/wc-frontend-manager/reviews/

      Thank You

Viewing 9 reply threads
  • The topic ‘Inquiry menu title hook’ is closed to new replies.