- This topic has 7 replies, 3 voices, and was last updated 4 years, 1 month ago by David.
-
AuthorPosts
-
January 29, 2020 at 11:26 am #1148527Grant
Hey I am trying to make a nice footer and could use some direction… I have placed the following code into the footer module and would like to make it so that it is one line on desktop or tablet and then three lines on mobile. Basically I don’t want
the word wrap to cause
the lines
to break
up
oddly…%copy% 2020 grantdb <br> Powered by <a href="https://wordpress.org/" target="_blank" rel="noopener">WordPress</a><br>Theme by <a href="https://generatepress.com/" target="_blank" rel="noopener">GeneratePress</a>
Is what I have so far, but it looks great on mobile but too tall on desktop/tablet.
Any tips?
Thanks!
January 29, 2020 at 11:31 am #1148536LeoStaffCustomer SupportHI there,
I think the easiest way would be adding that message twice and use the built-in hide-on class to hide one or another depending on the device:
https://docs.generatepress.com/article/responsive-display/#using-our-hide-on-classesLet me know if this helps ๐
January 29, 2020 at 11:45 am #1148556GrantAwesome! Hows this look? It works well but all good?
<div class="hide-on-desktop"> %copy% 2020 grantdb <br> Powered by <a href="https://wordpress.org/" target="_blank" rel="noopener">WordPress</a><br>Theme by <a href="https://generatepress.com/" target="_blank" rel="noopener">GeneratePress</a> </div> <div class="hide-on-mobile"> %copy% 2020 grantdb - Powered by <a href="https://wordpress.org/" target="_blank" rel="noopener">WordPress</a> - Theme by <a href="https://generatepress.com/" target="_blank" rel="noopener">GeneratePress</a> </div>
Thanks!
January 29, 2020 at 11:49 am #1148568LeoStaffCustomer SupportYou would want to add
hide-on-tablet
to one of the div as well.Otherwise it looks good!
January 29, 2020 at 11:55 am #1148576GrantHaha it showed both layouts on my tablet… Just for the sake of this thread here is the final code that I am using…
<div class="hide-on-desktop hide-on-tablet"> %copy% 2020 grantdb <br> Powered by <a href="https://wordpress.org/" target="_blank" rel="noopener">WordPress</a><br>Theme by <a href="https://generatepress.com/" target="_blank" rel="noopener">GeneratePress</a> </div> <div class="hide-on-mobile"> %copy% 2020 grantdb - Powered by <a href="https://wordpress.org/" target="_blank" rel="noopener">WordPress</a> - Theme by <a href="https://generatepress.com/" target="_blank" rel="noopener">GeneratePress</a> </div>
Thank you!!!!
January 29, 2020 at 11:56 am #1148578LeoStaffCustomer SupportNo problem ๐
March 17, 2020 at 4:48 pm #1197843GrantI am getting an optimization suggestion:
22 images are being stretched in the browser
regarding my footer images from the above code, any suggestions? Should I just ignore this?
Thanks!
Grant
March 18, 2020 at 4:34 am #1198217DavidStaffCustomer SupportHi there,
If thats related to your social icon images then yeah its safe to ignore.
-
AuthorPosts
- You must be logged in to reply to this topic.