탐색 건너뛰기

Open

Topic Tags: Compatibility

Overview of the issue

In WPResidence theme, the “Select User Type” dropdown in the registration modal fails to show translated user types on secondary language pages. Instead, when the registration modal is accessed on a translated page, the dropdown is empty.

Workaround

Please, make sure of having a full site backup of your site before proceeding.

  • Open ../wp-content/plugins/wpresidence-core/misc/plugin_help_functions.php file.
  • Look for line 285.
  • Replace:
      $user_type = array(
        esc_html__('User','wpresidence-core'),
        esc_html__('Agent','wpresidence-core'),
        esc_html__('Agency','wpresidence-core'),
        esc_html__('Developer','wpresidence-core')
      );
    
  • With:
        if (class_exists('sitepress')) {
            $user_type = array(
                esc_html__('Select User Type', 'wpresidence'),
                esc_html__('User', 'admin_texts_wpresidence_admin'),
                esc_html__('Single Agent', 'admin_texts_wpresidence_admin'),
                esc_html__('Agency', 'admin_texts_wpresidence_admin'),
                esc_html__('Developer', 'admin_texts_wpresidence_admin'),
            );
        } else {
            $user_type = array(
                esc_html__('Select User Type', 'wpresidence'),
                esc_html__('User', 'wpresidence'),
                esc_html__('Single Agent', 'wpresidence'),
                esc_html__('Agency', 'wpresidence'),
                esc_html__('Developer', 'wpresidence'),
            );
        }
    
  • Then go to WPML > String Translation page and click on the “Translate texts in admin screens »” link.
  • Look for the different roles (User, Agency…) under the [wpresidence_admin][wp_estate_visible_user_role] name and add them to String Translation.
  • Return to WPML > String Translation page and translate them.

답장을 남겨주세요

주제를 유지하고 다른 사람을 존중하십시오. 이 게시물과 관련 없는 문제에 대한 도움이 필요한 경우 지원 포럼을 사용하여 채팅을 시작하거나 티켓을 제출하십시오.

다음 태그를 사용할 수 있습니다.
<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>