inpsyde / wpml2mlp

Convert posts from an existing WPML multilingual site via WXR Export/Import for MultilingualPress
https://wordpress.org/plugins/wpml-to-multilingualpress/
GNU General Public License v2.0
10 stars 6 forks source link

Uncaught SyntaxError: Unexpected token u in JSON at position 0 at JSON.parse #64

Open fgamba opened 5 years ago

fgamba commented 5 years ago

Hi there,

Every time I try to choose a language for a given version of the website (see attached)

In this line of code: var data = JSON.parse( self.attr( 'data-export' ) ); I made a console.log and attr is undefined js-error

Please advice, thanks!

fgamba commented 5 years ago

On the other side, I commented the "data" var depicted above and replace the values in : $.ajax({ async: true, url: ajaxurl, type: "GET", data: { action : 'run_export', wpml2mlp : data.wpml2mlp, language : $('#inpsyde_multilingual_lang').val(), timezone : timezone }, for $.ajax({ async: true, url: ajaxurl, type: "GET", data: { action : 'run_export', wpml2mlp : data.wpml2mlp, language : $('#inpsyde_multilingual_lang').val(), timezone : timezone },

but I'm not sure which value I need to use in wpml2mlp, please advice

fgamba commented 5 years ago

Hi there, any updates?

Just FYI, I am using the last version of Wordpress and PHP 5.6