Title: WPML meta fix
Last modified: September 4, 2021

---

# WPML meta fix

 *  Resolved [Roi Webreach](https://wordpress.org/support/users/roi-webreach/)
 * (@roi-webreach)
 * [4 years, 8 months ago](https://wordpress.org/support/topic/wpml-meta-fix/)
 * hey, I had a problem with the plugin, and the guys from wpml fixed it. so please
   add this fix to the next version.
 * In wp-content/plugins/simple-lightbox/controller.php replace line 907:
 * `$pids[$p->id][] = $key;`
 * with:
 *     ```
       if ( class_exists( 'sitepress' ) ) {
           $current_language = apply_filters( 'wpml_current_language', NULL );
           $pids[apply_filters( 'wpml_object_id', $p->id, 'attachment', true, $current_language)][] = $key;
       } else {
           $pids[$p->id][] = $key;
       }
       ```
   

Viewing 1 replies (of 1 total)

 *  Plugin Author [Archetyped](https://wordpress.org/support/users/archetyped/)
 * (@archetyped)
 * [4 years, 8 months ago](https://wordpress.org/support/topic/wpml-meta-fix/#post-14852360)
 * Hi, that code appears to be tied to a specific theme, which would mean it would
   be non-functional for a lot of users.
 * In general, third-party plugins are supported via extensions to keep the core
   SLB plugin as lean as possible for all users. Please refer to the existing [proposal for a multilingual extension](https://github.com/archetyped/simple-lightbox/issues/205)
   to add your vote and feedback for WMPL support.
 * Thanks.

Viewing 1 replies (of 1 total)

The topic ‘WPML meta fix’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/simple-lightbox.svg)
 * [Simple Lightbox](https://wordpress.org/plugins/simple-lightbox/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/simple-lightbox/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/simple-lightbox/)
 * [Active Topics](https://wordpress.org/support/plugin/simple-lightbox/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/simple-lightbox/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/simple-lightbox/reviews/)

 * 1 reply
 * 2 participants
 * Last reply from: [Archetyped](https://wordpress.org/support/users/archetyped/)
 * Last activity: [4 years, 8 months ago](https://wordpress.org/support/topic/wpml-meta-fix/#post-14852360)
 * Status: resolved