SimpleMap Store Locator
Your plugin is not compatible with qTranslate (5 posts)

  1. JohnnyPea
    Posted 3 years ago #

    Unfortunately the plugin is not compatible with qTranslate plugin for localizations and it is not displaying correct language. For some reason it is looking for localization file in format "SimpleMap-.mo" for any language.

    Do you think you can do something with that?


  2. Glenn Ansley
    Plugin Author

    Posted 3 years ago #

    Probably not anytime soon. If anyone wants to work on translations, feel free to contact me from the web site. I can compensate you.

  3. madn3ss75
    Posted 3 years ago #

    If you edit a little bit of code you can resolve the issue quite eaily.
    Open simplemap/classes/simplemap.php
    Find the load_plugin_textdomain() call and delete it.
    Insted put an "init" call:
    add_action('init', array( &$this, 'init_plugin_lang'));
    Outside the function Simple_Map() declare this function:

    function init_plugin_lang(){
          $plugin_dir = basename( SIMPLEMAP_PATH );
          load_plugin_textdomain( $this->plugin_domain, 'wp-content/plugins/' . $plugin_dir . '/lang', $plugin_dir . '/lang' );

    Here you are. Your SimpleMap plugin is working togetherwith qTranslate.
    Remember to setup the .mo files for your language inside the /lang folder of the plugin.
    And don't forget that an (*eventual*) update to the plugin will blow up all of your edits, so pay attention when updating and backup your code before.


  4. madn3ss75
    Posted 3 years ago #

    You need another thing:
    - find

    // Scripts
    				wp_enqueue_script( 'simplemap-master-js', site_url() . '/?simplemap-master-js', array( 'jquery' ) );

    -replace with

    // Scripts
    				wp_enqueue_script( 'simplemap-master-js', site_url() . '/'.qtrans_getLanguage(). '/?simplemap-master-js', array( 'jquery' ) );

    This thing is evolving, but for the moment it seems to work properly.

  5. Pi-Ji
    Posted 3 years ago #

    Thanks madn3ss75.

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • SimpleMap Store Locator
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic