-
AuthorPosts
-
February 5, 2023 at 2:38 pm #1396745
Hello everyone,
Hello Mike,during the past weeks I have made some improvements to my website thanks to your help. Testing the website on several devices of my friends I have realized that there are still some layout issues.
When does it happen?
These issues occur on smartphones and tablets if they are turned and used in a landscape format. For the tablet I can say for that this happened on the tablet Huawei MediaPad M3 with 1200x1920px (I opened the website with 1920px horizontally. With 1200px horizontally there are no layout problems.) and on the smartphone Google Pixel 6 with 1080x2400px (I opened the website with 2400px horizontally. With 1080px horizontally there are no layout problems.).
And the same issues occur on tablets which have a high resolution. During my test this was a Samsung Tablet with 1752x2800px. In this case the layout showed the behavior already with 1752px horizontally.What are the issues with the layout? Main page / starting page (Startseite).
For example the screenshot ‘Screenshot_20230204-192715’ shows a part of the main page. You can see that there is an empty space before the image. It would be better if the image is in the middle and the text below or something like that. I assume that the whitespace on the left side of the picture occurs due to whitespace which is on the left and right side to the elements in the desktop view. However, if I open the website on the same device vertically everything is fine (see ‘Screenshot_20230204-192701’).What are the issues with the layout? Contact page (Kontakt).
Originally I had some issues with the picture on mobile devices, because it has always shown on the wrong position. I was able to fix this with your help by adding the code:@media only screen and (max-width: 767px) { #top.page-id-156 #av_section_1 .entry-content-wrapper { display: flex !important; flex-wrap: wrap !important; } #top.page-id-156 #av_section_1 .flex_column.avia-builder-el-first { order: 2 !important; } #top.page-id-156 #av_section_1 .flex_column.avia-builder-el-last { order: 1 !important; } }
This has been posted in this thread:
https://kriesi.at/support/topic/best- way-to-combine-text-images-to-ensure-that-the-responsiveness-still-works/Now, I have realized that the picture is shown at the wrong position on devices with a higher resolution. On the mentioned devices and given the mentioned circumstances at the beginning of the post the picture is always shown at the very end of the page. That is below the send-button, see ‘Screenshot_20230204-192115’. It would be great if the picture would always be shown above the headline.
I hope you can give me some ideas how to fix this. Thank you very much in advance.
Best regards
willbaerFebruary 5, 2023 at 5:48 pm #1396769Hey willbaer,
Thanks for your screenshots and the screen sizes, for issue on the homepage (Screenshot_20230204-192115) where the text column is below the image column, I tried the different screen sizes above in my browser Dev Tools but I couldn’t recreate the issue, I don’t know why and I don’t have a real tablet to test on, but in my browser Dev Tools I did recreate the issue between 768px – 989px please see the first screenshot in the Private Content area.
At this size the text column and the image column seem to be on the wrong sides and the text column is below the image column with a white space created by an empty 1/4 column used as a placeholder for larger screens, to correct I tested this css:@media only screen and (min-width: 768px) and (max-width: 989px) { #top.home #av_section_6 .entry-content-wrapper { display: flex !important; flex-wrap: wrap !important; } #top.home #av_section_6 .flex_column.avia-builder-el-54 { order: 1 !important; display: flex; margin-left: 0; margin-right: 4%; width: 46%; } #top.home #av_section_6 .flex_column.avia-builder-el-56 { order: 2 !important; display: flex; flex-direction: column; margin-top: 0; } #top.home #av_section_6 .flex_column.av_one_fourth.el_after_av_hr.first { display: none; } }
Please see the second screenshot in the Private Content area.
Please give this a try, if you see the same error at the other sizes you listed above you could try adjusting the media query size to match, if this is only occurring on devices in landscape mode you could add it to the media query like this:
@media only screen and (min-width: your-size px) and (max-width: your-size px) and (orientation: landscape) { ... }
Please try this and then we will look at your second issue in case I’m misunderstanding something.Best regards,
MikeMarch 7, 2023 at 4:03 pm #1400372Hello Mike,
your CSS code helped to get rid of the white space. The result is that you can find the text below the image in the landscape mode on the smartphone. As shown in the attached screenshot, both, the image and the text are aligned now to the left. Is it possible to align it to the middle in this case?
Thank you very much in advance. I promise that I will answer this time straight.
Best regards
willbaerMarch 7, 2023 at 6:39 pm #1400380Hi,
Try adding this css:@media only screen and (min-width: 768px) and (max-width: 989px) { .responsive #top.home #av_section_6 .av_one_fourth.first + .av_one_fourth.flex_column_div.avia-builder-el-54 { margin-left: 0; } }
After applying the css, please clear your browser cache and check.
Best regards,
MikeMarch 7, 2023 at 8:57 pm #1400405I have added this to the column with the image (hope this was right), but it does not affect the image at all. It looks still the same and is not centered. I have used new inkognito tabs each time, so that I was asked to accept or decline the cookies.
I would suggest that we give it one last try, if it still does not work then, we should have a quick look at the contact page.
Best regards
willbaerMarch 8, 2023 at 7:57 pm #1400507Hi,
Thanks for the feedback, I see an error on your site now and based on your last comment I believe that you added the css I posted above to the custom class field, please remove this and add the css to: Enfold Theme Options ▸ General Styling ▸ Quick CSS field, then clear your browser cache and any cache plugin, and check.Best regards,
MikeMarch 9, 2023 at 8:19 pm #1400592My mistake, thanks a lot for the hint! I have moved to coding to the correct Quick CSS field. It did not change anything using the smartphone and tablet in the landscape mode:
Overall I have now this coding in the Quic CSS field:
@media only screen and (max-width: 767px) { #top.page-id-156 #av_section_1 .entry-content-wrapper { display: flex !important; flex-wrap: wrap !important; } #top.page-id-156 #av_section_1 .flex_column.avia-builder-el-first { order: 2 !important; } #top.page-id-156 #av_section_1 .flex_column.avia-builder-el-last { order: 1 !important; } }
@media only screen and (min-width: 768px) and (max-width: 989px) { .responsive #top.home #av_section_6 .av_one_fourth.first + .av_one_fourth.flex_column_div.avia-builder-el-54 { margin-left: 0; } }
The first part was needed to improve the layout on the contact page. Maybe they influcence each other?
Best regards
MichaelMarch 10, 2023 at 1:11 pm #1400674Hi,
When I check on mobile (425px) in landscape mode the image and text are lined up, please see the screenshot in the Private Content area.
Perhaps try clearing your mobile cache, iPads & iPhones can be hard to clear the cache, often you need to also clear the history to fully purge the cache, following these steps for Safari and note Step 4 where you will Clear the History.
I also notice the column still has the error for invalid class name, please check that you have removed the css for the “custom class” field.
If you have trouble with this please include an admin login in the Private Content area so we can be of more assistance.Best regards,
MikeMarch 20, 2023 at 9:03 pm #1401833This reply has been marked as private.March 22, 2023 at 11:26 pm #1402055Hi,
Thank you for the link to your site and your patience, for your homepage to make your image under Über mich line up over the lower paragraph on mobile in landscape, please try this css:@media only screen and (max-width: 989px) and (orientation: landscape) { .responsive #top.home #av_section_6 .av_one_fourth.first.av-hide-on-mobile.avia-builder-el-53 { display: none; } }
Best regards,
MikeMarch 24, 2023 at 4:58 pm #1402373Hello Mike,
this coding helped to align image and text on the ‘home’ page. So this one is fixed.
It had no effect on the ‘über mich’ page.
I think maybe we should just leave it the way it is. Probably not too many people have such high resolution devices when used vertically. And probably not many people will visit the website holding their devices horizontally. I think it makes more sense to target the issues when necessary.
Thanks a lot for you help.
Best regards
MichaelMarch 24, 2023 at 10:09 pm #1402406Hi,
Glad we were able to help, if you have any further questions please create a new thread and we will gladly try to help you. Thank you for using Enfold.Best regards,
Mike -
AuthorPosts
- The topic ‘Layout issues on smartphones and tablets with high resolution / landscape format’ is closed to new replies.