- This topic has 6 replies, 2 voices, and was last updated 4 months, 1 week ago by
David.
-
AuthorPosts
-
September 18, 2020 at 3:26 am #1448358
Gary
I have setup a Hero Header with GP Elements and it all works fine. The setting include Merge and Full Screen image.
I have 3 lines of text in the Hero Header.
As I am using WPML, these 3 lines need translating. That is the easy part. The Elements can be translated using WPML. I have done that. But the problem is that my ‘Full Screen’ settings don’t work in the translated language.
This is what is looks like in Engish:
https://www.ipohgo.com/This is what it looks like in Chinese:
https://www.ipohgo.com/zh-hans/September 18, 2020 at 6:58 am #1448595David
StaffCustomer SupportHi there,
thats odd – simplest fix would be to add
full-height
to the Element classes field in the Header Element. Then add this CSS:.page-hero.full-height { min-height: 100vh; }
Documentation: http://docs.generatepress.com/
Adding CSS: http://docs.generatepress.com/article/adding-css/September 19, 2020 at 9:09 pm #1450491Gary
Hi David,
Thanks for this, but sadly it didn’t work. Nothing has changed:
September 20, 2020 at 4:53 am #1450801David
StaffCustomer SupportI am not a WPML user – does it require you to create a separate Element for each language?
Documentation: http://docs.generatepress.com/
Adding CSS: http://docs.generatepress.com/article/adding-css/September 20, 2020 at 5:04 am #1450812Gary
No, WPML doesn’t require that. All the element/post/page settings are supposed to stay the same, and other than this particular case, that is exactly what happens throughout my site.
It’s very odd.
I’ve inspected the page and I note that the code is different but I can’t understand why.
On my English language page, it is:
<div class="page-hero hide-on-mobile full-height" style="background-position-y: 0px;">
But on my Chinese-language page it is:
<div class="page-hero hide-on-mobile">
It’s using exactly the same element, so I don’t understand why the height and style are being removed.
September 20, 2020 at 5:11 am #1450823Gary
Hi David,
I have finally resolved it.
WPML has a set of ‘system fields’ for each page/post/element etc. These are usually not touched but I have just inspected them and noticed there was a system field titled ‘_generate_hero_full_screen’ that was set to ‘Don’t Translate’. I changed the setting to ‘Copy’ and hey presto, it now works.
I have put this info here in case it happens to another GP user in the future.
September 20, 2020 at 5:50 am #1450866David
StaffCustomer SupportAwesome – yeah i am sure we have answered this type of query before ( Tom normally deals with translations ) – thanks for sharing, at least i have an idea where to direct WPML users in the future.
Documentation: http://docs.generatepress.com/
Adding CSS: http://docs.generatepress.com/article/adding-css/ -
AuthorPosts
- You must be logged in to reply to this topic.