Background of the issue:
We have an issue that we have translated our website and once we changed the languages from the original language to translated languages the site goes from wider to tighter. Link to a page where the issue can be seen: hidden link
Symptoms:
The page layout changes from wider to tighter and smaller after switching languages.
Questions:
What is the possible issue causing the page layout to change from wider to tighter after switching languages? and how we can fix it
Thank you for contacting WPML Support. I can see the issue on your site. I've examined the source code of Arabic language and it seems an error-page ID is assigned to the body tag and some CSS is added to the Arabic language which apparently causes this issue. So, please follow the below steps and let me how it goes:
1. Please make sure you have followed the step-by-step instructions from this doc: hidden link especially the theme option settings section as you can see in the attached screenshot.
2. If the issue still persists, please enable error reporting on your site as I need to see the details of the latest error log to understand the cause of the issue better. To enable it, open your ‘wp-config.php’ file and look for ‘define(‘WP_DEBUG’, false);’. Change it to:
// Enable WP_DEBUG mode
define( 'WP_DEBUG', true );
// Enable Debug logging to the /wp-content/debug.log file
define( 'WP_DEBUG_LOG', true );
// Disable display of errors and warnings
define( 'WP_DEBUG_DISPLAY', false );
@ini_set( 'display_errors', 0 );
define( 'SCRIPT_DEBUG', true );
After adding the above code, please try visiting the Arabic language page and reloading the backend/frontend of your site again, and if this process creates a debug.log file in your site's wp-content directory. Please send me its contents.
I would like to confirm that regarding your point and solutions number 1 we confirm that we have previously followed very well as the instruction in the document.
Regarding your point number 2 it very hard foe us to comply with and do it, so is there any other type of solutions to fix the issue.
Many thanks for your kind help and let me tell you that the problem has been solved
and we found out that once we activate the "WPML Media Translation " makes the problem to our site and after we deactivate "WPML Media Translation " the site back to normal
Thanks for the support.
alawsT confirmed that the issue was resolved on 2024-09-28 01:41:30.
This ticket is now closed. If you're a WPML client and need related help, please open a new support ticket.