Post by Boppe » Tue May 21, 2019 2:28 pm

OC 2

On my homepage I have text made in a Html module. A part of the text is h1. I understand that the font size of the h1 is set in stylesheet.css.
On desktop it looks good but on a mobile device I would like to reduce the font size.

Is it possible to reduce the h1 font size ONLY on the homepage and ONLY om mobile devices?

Active Member

Posts

Joined
Mon Apr 29, 2013 10:09 pm

Post by dparakhiya » Tue May 21, 2019 3:03 pm

Boppe wrote:
Tue May 21, 2019 2:28 pm
Is it possible to reduce the h1 font size ONLY on the homepage and ONLY om mobile devices?
yes, it's possible
using media query :
read more at :
https://www.tutorialrepublic.com/css-tu ... ueries.php
https://www.w3schools.com/css/css3_mediaqueries_ex.asp

For quick, professional OpenCart support
Online
contact me on skype : dparakhiya_1
email : dipneshp@gmail.com


User avatar
New member

Posts

Joined
Fri Jul 28, 2017 1:13 pm
Location - India

Post by thekrotek » Tue May 21, 2019 3:31 pm

dparakhiya wrote:
Tue May 21, 2019 3:03 pm
using media query :
Media query works for ALL devices, not only mobile. It only checks for window size.

Professional OpenCart extensions, support and custom work.
Contact me via email or Skype by support@thekrotek.com


User avatar
Expert Member

Posts

Joined
Sun Jul 03, 2016 12:24 am


Post by dparakhiya » Tue May 21, 2019 3:52 pm

thekrotek wrote:
Tue May 21, 2019 3:31 pm
dparakhiya wrote:
Tue May 21, 2019 3:03 pm
using media query :
Media query works for ALL devices, not only mobile. It only checks for window size.
I mean this is the way you fix.
this is not a full answer
I gave a just way to solve this

For quick, professional OpenCart support
Online
contact me on skype : dparakhiya_1
email : dipneshp@gmail.com


User avatar
New member

Posts

Joined
Fri Jul 28, 2017 1:13 pm
Location - India

Post by thekrotek » Tue May 21, 2019 3:56 pm

dparakhiya wrote:
Tue May 21, 2019 3:52 pm
I mean this is the way you fix.
this is not a full answer
I gave a just way to solve this
With CSS you can only limit the style definitions to certain screen resolutions. To limit them by devices, PHP has to be used. Not sure, if the guy really needs to limit it by devices.

Professional OpenCart extensions, support and custom work.
Contact me via email or Skype by support@thekrotek.com


User avatar
Expert Member

Posts

Joined
Sun Jul 03, 2016 12:24 am


Post by Boppe » Tue May 21, 2019 8:47 pm

Hi.
Thanks for your answers.

That's what I need change the heading size for certain resolutions.

I'm still studying media query tring to figure out how to make the changes and where.

Active Member

Posts

Joined
Mon Apr 29, 2013 10:09 pm
Who is online

Users browsing this forum: No registered users and 42 guests