Osclass Support Forums
Osclass theme support => Zara Osclass Responsive Theme => Topic started by: Виталий Василенко on December 07, 2016, 01:20:44 PM
-
The header.php file
I put in function for the output h1 tag
The regular version all OK
I want to hide h1 in the mobile version
tell me how to do it
print Screen http://prntscr.com/dgfcrq
-
Sorry for my bad english
-
You can use different tools that help you customize mobile view of website, like:
http://responsivetest.net/#u=http://zara.mb-themes.com/|320|480|1 (http://responsivetest.net/#u=http://zara.mb-themes.com/|320|480|1)
-
How to view the mobile version I know
I want to hide h1 in the mobile version
print Screen
-
http://www.w3schools.com/css/css3_mediaqueries_ex.asp
-
Hi, resolve this using css
put this code at the end of your style.css
.mobileHide { display: inline;}
/* Smartphone Portrait and Landscape */
@media only screen
and (min-device-width : 320px)
and (max-device-width : 480px){ .mobileHide { display: none;}}
A go to your header and replace add this
<h1 class="mobileHide">
TEXT OR IMAGE NOT FOR MOBILE HERE
</h1>
This is the tutorial that I follow
https://blog.hubspot.com/marketing/site-content-only-mobile-viewers-can-see-ht#sm.0001mb01u3izif0htag2o89athefz
-
Many thanks.
I did everything you said.
Does not work :-(
Please tell me why so
-
even print screen
-
and
-
I think you should increase range of min and max width.
-
.mobileHide { display: inline;}
/* Smartphone Portrait and Landscape */
@media only screen
and (min-device-width : 10px)
and (max-device-width : 490px){ .mobileHide { display: none;}}
no effect
-
Try with this:
<div class="mobileHide"><h1>text here</h1></div>
Remember to test with different types of codes, for example
<center class="mobileHide"><h1>text here</h1></center>
<ul class="mobileHide"><h1>text here</h1></ul>