Responsive logo on the left of box template

25 April, 2016
GK User
Sun May 01, 2016 11:10 am
Hi everybody,
Nice template, and quick.
I am having trouble just because I chose logo instead of text and as the text resize perfecly, the logo does not and therefore it is too high on small devices (smartphone, tablets).
Can you help please ?
Here is the issue :
Capture d’écran 2016-05-01 à 11.49.06.png

tablet.jpg


Thanks for your help
User avatar
Expert Boarder

GK User
Sun May 01, 2016 11:34 am
Hello,

In the tablet.css please add:

Code: Select all
#gkLogo {
    margin-left: 0;
}
#gkLogo img {
    height: 45px;
}
User avatar
Moderator

GK User
Sun May 01, 2016 8:52 pm
Thanks very much Tidy, this is working perfectly, but as soon as there is an update of the css, I will have to change again. Is there a solution in the override.css file instead ? That would be much cleaner. Don't you think ? Or is there a global solution that could be great for all of us using a logo instead of text ?
Thanks again for you reply a 1st of May day when we should not work (and above all a sunday!)
Regards
kris
User avatar
Expert Boarder

GK User
Mon May 02, 2016 9:21 pm
If you want to make sure that none of your changes will be lost during the update, then please put your code (with media query which uses a value for your tablet CSS code) in the template Advanced Settings -> Custom CSS code:

Code: Select all
@media (max-width: 1040px) {
#gkLogo {
    margin-left: 0;
}
#gkLogo img {
    height: 45px;
}
}
User avatar
Moderator

GK User
Sun May 08, 2016 4:41 pm
Thanks a lot Tidy !
For those who did not understand right away (like me) this code can also be put in the file override.css that is located here : /templates/gk_box/css/override.css instead.
I changed the code to have a bigger logo :
Code: Select all
    @media (max-width: 1040px) {
    #gkLogo {
        margin-left: 0;
    }
    #gkLogo img {
      margin-left: -1px;
      margin-top: -3px;
        height: 68px;
    }
    }
User avatar
Expert Boarder

GK User
Wed May 18, 2016 9:52 pm
hi,

I have the same problem, my logo does not fit the cell or tablet

I placed code is as follows

my site : http://www.salvemosvitacura.cl/

My code does not work

Code: Select all
#gkLogo.cssLogo {
    background-image: url("../images/style1/logo.jpg" no-repeat scroll 0 0);
     position: absolute;
}

#gkLogo.cssLogo {
    background: transparent url("../images/style1/logo.jpg") no-repeat scroll 0 0;
    height: 180px;
    width: 200px;
   position: absolute;
   margin-left: 50px;
    margin-top: 50px;
    
}
#gkLogo {
    display: block;
    float: left;
    height: 40px;
    margin: 0px;
    padding: 0;
    text-indent: -999em;
    text-shadow: none;
    width: 124px;
}

/*Logo small*/

#gkLogoSmall.cssLogo {
    background-image: url("../images/style1/logos.jpg" no-repeat scroll 0 0);
     position: absolute;
}

#gkLogoSmall.cssLogo {
    background: transparent url("../images/style1/logos.jpg") no-repeat scroll 0 0;
    height: 90px;
    width: 100px;
   position: absolute;
   /*margin-left: 50px;
    margin-top: 50px;*/
    
}


#gkLogoSmall {
    display: block;
    float: left;
    height: 40px;
    margin: 0px;
    padding: 0;
    text-indent: -999em;
    text-shadow: none;
    width: 124px;
}
User avatar
Platinum Boarder

GK User
Wed May 18, 2016 10:19 pm
I had a quick look and I think you forgot something like that : @media (max-width: 1040px) see my code. That is just what I added to have it working properly. I do not understand why you have so much code to add.
Regards
Kris
User avatar
Expert Boarder

GK User
Wed May 18, 2016 10:21 pm
are those in the template I added what you say, but nothing happens
User avatar
Platinum Boarder

GK User
Thu May 19, 2016 7:13 am
in this custom css file : /templates/gk_box/css/override.css
User avatar
Expert Boarder

GK User
Fri May 20, 2016 3:11 am
yes, in this file
User avatar
Platinum Boarder

GK User
Fri May 20, 2016 7:35 am
Please just copy and paste my code (changing your url for the logo) replacing your code.
Your code is really different from mine.
I am sorry, I am not a developper, nor a coder (no link with gavick staff), just a simple user trying to work with css. I am not a pro that can help more than that.
Hope it will work. It should.
Regards
Kris
User avatar
Expert Boarder

GK User
Fri May 20, 2016 1:48 pm
Thanks, but I need you to answer me Gavick staff, its code is different because it is not the same template

Thank you
User avatar
Platinum Boarder

GK User
Sat Nov 19, 2016 1:12 pm
Works perfectly! Thanks!

kristobal1969 wrote:Thanks a lot Tidy !
For those who did not understand right away (like me) this code can also be put in the file override.css that is located here : /templates/gk_box/css/override.css instead.
I changed the code to have a bigger logo :
Code: Select all
    @media (max-width: 1040px) {
    #gkLogo {
        margin-left: 0;
    }
    #gkLogo img {
      margin-left: -1px;
      margin-top: -3px;
        height: 68px;
    }
    }
User avatar
Senior Boarder


cron