Hi, I’m new
to umbraco so I’ve started out with the Fanø starter-kit. I can see that the
image on the pages are resizing perfect but not the logo image, can some one tell
me how to make the logo re-size from a max to a minimum fixed size? Thanks
I just want to encourage you to add the max-width declaration in an external stylesheet rather than doing it inline. Just to keep things clean. Since the logo is pulled from Umbraco then it of course needs to be inlined.
But put this in an external css file :) - I think that the fanoe.css is located in the /css/ folder if I remember correctly.
I agrre with you Jan. Keep it clean J But why are the height, width and background color in-line in the master template? I can see that the height and width are in the css as well…
I'd recommend actually using a combination of both css and ImageProcessor for this.
Use Imageprocessor to set a maximum possible width/height in-line, that way you ensure that the file size is kept low - A 4MB image is still 4MB if you are only scaling via CSS.
Use CSS max-width in your external style-sheet to determine the width for whatever breakpoints you have determined.
Dynamic re-size logo image
Hi, I’m new to umbraco so I’ve started out with the Fanø starter-kit. I can see that the image on the pages are resizing perfect but not the logo image, can some one tell me how to make the logo re-size from a max to a minimum fixed size? Thanks
Hi Gert and welcome to our :-),
You can do it by find this line in the master template under settings --> Templates --> Master and add max-with: 100%;
So the full line looks like this:
You can also do it in the stylesheet find the rule for the brand class.
Hope this helps,
/Dennis
Thank! works like a charm...guess I need a brush up on my HTML/CSS as well :-)
/Gert
Hi guys
I just want to encourage you to add the max-width declaration in an external stylesheet rather than doing it inline. Just to keep things clean. Since the logo is pulled from Umbraco then it of course needs to be inlined.
But put this in an external css file :) - I think that the fanoe.css is located in the /css/ folder if I remember correctly.
/Jan
I agrre with you Jan. Keep it clean J But why are the height, width and background color in-line in the master template? I can see that the height and width are in the css as well…
Hi Gert
It's not set using CSS properties - It's parameters for the image handler that scales the selected image.
/Jan
okay.. I see
I'd recommend actually using a combination of both css and ImageProcessor for this.
is working on a reply...