ข้ามไปยังเนื้อหาหลัก ข้ามไปยังแถบด้านข้าง

Waiting for author

Topic Tags: Compatibility

Overview of the issue

When using Bricks with WPML, you might experience an issue where translated image ALT texts are not shown correctly in the Image element. If the image caption is taken from the media attachment instead of a custom caption, the front end may display the original caption from the source image.

Workaround

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

  • Open the …/wp-content/themes/bricks/includes/elements/image.php file.
  • Look for line 751.
  • Replace:
    $image_id   = isset( $image['id'] ) ? $image['id'] : '';
            
  • With:
    $image_id   = isset( $image['id'] ) ? apply_filters( 'wpml_object_id', $image['id'], 'attachment', TRUE  ) : '';
    $image['id'] = $image_id;
            

แสดงความคิดเห็น

โปรดอยู่ในหัวข้อและให้ความเคารพผู้อื่น หากคุณต้องการความช่วยเหลือในประเด็นที่ไม่เกี่ยวข้องกับโพสต์นี้ ให้ใช้ฟอรัมสนับสนุนของเราเพื่อเริ่มการแชทหรือส่งตั๋ว.

คุณสามารถใช้แท็กเหล่านี้:
<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>