This is the technical support forum for WPML - the multilingual WordPress plugin.
Everyone can read, but only WPML clients can post here. WPML team is replying on the forum 6 days per week, 22 hours per day.
|February 18, 2019 at 12:38 pm #3212229|
Hi there! Because of a lot of images we have (90k aprox and will be more)
We wold like to disable Media Translation and delete all unnecessary data form database.
Can you please describe me an example to delete unnecessary data from database if i am will not use Media Translation?
In my plan i wold to this SQL: "DELETE FROM wp_icl_translations WHERE element_type = 'post_attachment';"
Is it enough only delete image related rows from _icl_translations table? Or there is more i need to delete?
|February 19, 2019 at 7:33 am #3215270|
Languages: English (English ) Spanish (Español )
Timezone: Europe/Madrid (GMT+02:00)
Will these images be viewed/viewable from all language spaces when navigating your site?
If so, you will need the duplicated attachment entries the images for them to be seen. Otherwise, you may encounter blank spaces or grey image placeholders in secondary languages on the frontend
I would strongly recommend to first test the impact on the frontend with a few test cases before executing a massive delete.
However, to answer your technical question, to remove the affects of WPML Media, you will need to reverse the steps that you find here:
The best order to execute those steps in is something you will need to test yourself but I do think you will need to write severa queries using the icl_translations table as a directory. It might be easier to just eliminate all of your media and re-install the content from scratch with all Media options turned off - but this depends on your state of existing content in other langauges.
There is no way to turn off Media Translation in the core product apart from making sure you do not check any of the Step 5 options. But once again, I emphasize, you may not be able to visualize any images in secondary languages on your frontend.
I hope this answers your question.
|February 19, 2019 at 9:04 am #3215601|
My issue is resolved now. Thank you!