Banner Logo

Be a part of the family: Connect, Receive Support,
Contribute, and Reap Abundant Rewards!

Fixing the appearance of Vendor badging below product title

WCMp Advanced Frontend Manager

Resolved
Viewing 11 reply threads
  • Author
    Posts
    • #115676
      charliexstanford
      Participant

      Hello,

      Greetings & a very happy new year!

      I am having some difficulties regarding the appearance of Vendor badging below the title. I also contacted my theme support but they weren’t able to completely understand the issue.

      The vendor badging ” Sold by test vendor” is not appearing properly.

      Please see this infographic – https://prnt.sc/ziup9k
      You can test this functionality on this page – https://drive.google.com/file/d/100vY3iF5x2F4PIAS8cIT1XS_g-c3r1TE/view?usp=sharing

      Please let me know how can I fix this.

      Thank you
      Respectfully,
      Charlie

    • #115740

      Hi,
      Kindly make sure that you are enabled “sold by” text setting from the back end.
      Checkout this image – https://prnt.sc/zlnbdb

      Regards,

    • #115862
      WCMp Admin
      Keymaster

      Reply on behalf of Charlie as he is unable to post due to some glitch:

      Hello,

      That option is enabled. The problem however is with theme compatibility. My colleague contacted the theme support but they weren’t able to address the issue.

      Here is their last reply on the thread – https://xtemos.com/forums/topic/underline-not-appearing-in-links-and-some-other-fix/#post-266948

      Could you please check and let me know how to fix this? – https://prnt.sc/ziup9k

      Regards,
      Charlie

    • #115817
      charliexstanford
      Participant

      Hello,

      Yes, that feature is enabled. The problem is with theme compatibility. My collegue opened a thread with theme suppport but they were unable to resolve the solution as desired.

      Here is the thread – https://xtemos.com/forums/topic/underline-not-appearing-in-links-and-some-other-fix/#post-266666

      That being said, can you look into it and see if it can be fixed ? – https://prnt.sc/ziup9k

      Thank you
      Charlie

    • #115818
      charliexstanford
      Participant

      Hello,

      Yes, that setting is enabled. The problem seem to be with theme compatibility.

      My collegue opened a thread at theme support but they weren’t able to address the solution as desired – https://xtemos.com/forums/topic/underline-not-appearing-in-links-and-some-other-fix/#post-266666

      Could you please look into it and see if this can be fixed? – https://prnt.sc/ziup9k

      Thank you
      Charlie

    • #115819
      charliexstanford
      Participant

      Hello,

      Yes, that setting is enabled. The problem seem to be with theme compatibility.

      My collegue opened a thread at theme support but they weren’t able to address the solution as desired – https://xtemos.com/forums/topic/underline-not-appearing-in-links-and-some-other-fix/#post-266666

      Could you please look into it and see if this can be fixed? – https://prnt.sc/ziup9k

      Thank you,
      Charlie

    • #115824
      charliexstanford
      Participant

      Hello,

      That option is enabled. The problem however is with theme compatibility. My colleague contacted the theme support but they weren’t able to address the issue.

      Here is there last reply on the thread – https://xtemos.com/forums/topic/underline-not-appearing-in-links-and-some-other-fix/#post-266948

      Could you please check and let me know how to fix this? – https://prnt.sc/ziup9k

      Regards,
      Charlie

    • #115953

      As the issue that you are facing is due to that theme that you are using so only the theme author can resolve it. So kindly reach out to your theme author.

    • #116474
      charliexstanford
      Participant

      Alright, I understand. Both of you were redirecting each other for the issue and in the end, I need to solve it myself. Fortunately, the problem is solved.

      Anyways, can you tell me a snippet to display the vendor’s first name in the email, please?

      I tried default woocommerce shortcodes but they didn’t worked.

      I also see this code prints the full name or shop name of the vendor –

      <p><?php printf(esc_html__( 'Hello %s, your %s store orders report stats are as follows:', 'dc-woocommerce-multi-vendor' ),  $vendor->page_title, $report_data['period']); ?></p>
      Copy

      But I need to print only FIRST NAME so it appears friendly.

      I need to display – Hello [Vendor’s first name],

      Please refer to the two screenshots attached in this message.

    • #116580

      Hi,
      Override templates/emails/vendor-orders-stats-report.php template by copying it to yourtheme/dc-product-vendor/emails/vendor-orders-stats-report.php

      remove line no 22.
      add below code after line no 21.

      <?php $user =  get_user_by( 'ID', $vendor->ID ); ?>
      <p><?php printf(esc_html__( 'Hello %s,<br>Your %s store orders report stats are as follows:', 'dc-woocommerce-multi-vendor' ),  $user->first_name, $report_data['period']); ?></p>
      Copy

      Regards,

    • #116624
      charliexstanford
      Participant

      Thank you for that. That wil be tested in real in next email sent by the plugin.

      We have encountered a different major issue.

      In order to prevent the vendor to upload a file of more than 2 MB, I have added this code:

      // Limit non admins lets say vendors to have upload limit of 2 mb
      function limit_upload_size_limit_for_non_admin( $limit ) {
      if(is_user_wcmp_vendor(get_current_user_id())){
          $limit = '2048000'; // 1kb in bytes
        }
        return $limit;
      }
       
      add_filter( 'upload_size_limit', 'limit_upload_size_limit_for_non_admin' );
       
       
      function apply_wp_handle_upload_prefilter( $file ) {
      if(is_user_wcmp_vendor(get_current_user_id())){
          $limit = 2048000; // 1kb in bytes
          if ( $file['size'] > $limit ) {
            $file['error'] = sprintf( __( 'ERROR: File size limit is %d MB.' ), $limit);
          }
        }
        return $file;
      }
       
      add_filter( 'wp_handle_upload_prefilter', 'apply_wp_handle_upload_prefilter' );
      Copy

      This works perfectly fine but the problem is if you disable the WCMP plugin ( for any reason may be testing), the whole admin area of the website breaks. It gives Fatal error.

      It looks like this – https://drive.google.com/file/d/1d4NTcMjbYIE-xhZpgRlUsKjz6jbkCiMM/view?usp=sharing

      Then we have to disable the (upload limit) code I mentioned above by editing functions.php in FTP to bring back the admin of site.

      Please suggest a fix.

    • #116685

      Hi,
      Remove the previous code and add this updated code

      // Limit non admins lets say vendors to have upload limit of 2 mb
      function limit_upload_size_limit_for_non_admin( $limit ) {
      	if( function_exists( 'is_user_wcmp_vendor' ) ){
      		if(is_user_wcmp_vendor(get_current_user_id())){
         			$limit = '2048000'; // 1kb in bytes
        		}
      	}
        return $limit;
      }
       
      add_filter( 'upload_size_limit', 'limit_upload_size_limit_for_non_admin' );
       
       
      function apply_wp_handle_upload_prefilter( $file ) {
      	if( function_exists( 'is_user_wcmp_vendor' ) ){
      		if(is_user_wcmp_vendor(get_current_user_id())){
      		    $limit = 2048000; // 1kb in bytes
      		    if ( $file['size'] > $limit ) {
      		      $file['error'] = sprintf( __( 'ERROR: File size limit is %d MB.' ), $limit);
      		    }
      		}
      	}
        return $file;
      }
       
      add_filter( 'wp_handle_upload_prefilter', 'apply_wp_handle_upload_prefilter' );
      Copy

      Regards,

Viewing 11 reply threads

The topic ‘Fixing the appearance of Vendor badging below product title’ is closed to new replies.