How to put logo in Navbar without png square - html

Using template engine as PUG
Html body
nav#navbar
ul.flex-container
div#logo
img(src='/static/logo3.png')
This is what image logo3.png looks
Can you suggest any css property?
Or photoshop tool to do it.
Searched but found opacity property which doesn't help.

You should use Google for more of these simplest tasks. This is not the right place to ask these type of questions. You can use an online background remover like https://remove.bg to remove backgrounds if you are not familiar with image editing apps. Btw, here's your updated image:

We can use background remover online tool as Vivek mention.
We can also do it by using css *Invert which changes white background to black. We can also use contrast and other property for it *Css filter function
#logo img{
filter: invert(1);
height: 50px;
width: 60px;
}
This is result of invert function
Thanks everyone who helped me in this!

Unfortunately this image is not transparent, you can see the gray and white chessboard pattern in the background.
I suggest you should use a photo editing app to select the content and delete everything other than the selection.

Related

CSS/SCSS background color like Microsoft Sign In page

I really like the style background color of the Microsoft Sign In page and I kinda want to learn about that also apply to my project for school. But when I inspect it, I can't see any style codes. Does CSS or SCSS can do that? I'm not really sure. Thanks
Here is the page that I'm talking about: Microsoft Sign In
You can see my fiddle to get Idea how to do this.
https://jsfiddle.net/rkm1994/0ewnsu7h/
- For Login
source:- https://speckyboy.com/login-pages-html5-css/
div{
height: 500px;
width: 500px;
background-image: linear-gradient(120deg,#f0c9f8,#f7eff6);
}
<div></div>
here is the thing i tried to make it for you hope it will help for the background...

Backround of my website is not changing color

So I am really new at programming (literally started yesterday lmao). So I wrote the code and everything and the backround color just doesn't want to change to black. I also have an issue where my image is not showing up on my webiste (it used to but now its only an blank square).
Thanks for answers :)
Please check your CSS file, in CSS file yoou write background:red; so please change that with below code.
<style>
body
{
background-color:red;
}
</style>
For background, you need to write complete term background-color: red; to make it work.
For image, make sure that the image exists in the same directory as the HTML file as you are not giving any extra path in your code.
Also, I would suggest that you go through any beginner guide on youtube first so that most of your queries are answered.
For colouring background, you need to change this:
body { background-color: red; }
And for your image issue, make sure you are entering the right path of the image.
You can also refer here: https://www.w3schools.com/tags/tag_img.asp

Color overlay on shape

I've got a small problem.
I want to create an overlay effect on the picture in the following jsfiddle.
http://jsfiddle.net/39gud4bh/1/
<div>
<img id="bubble" src="http://png-1.findicons.com/files/icons/2711/free_icons_for_windows8_metro/128/speech_bubble.png">
<img src="http://s30.postimg.org/lptvfyod9/speech_bubbleorange.png">
</img>
</div>
#bubble {
}
I want the overlay to have the color #ff9f2d
How is this possible? Been trying litterally everything i could find. The problem is that the image (might not be in jsfiddle) is a shape with a transparent background. This causes all my attempts to background/foreground filter the color to recolor the whole square instead of just the shape.
Really need some help.
In advance - Thank you!
EDIT - Fiddle has been updated to entail the desired outcome of the CSS on the grey bubble.
I don't think you can turn that yellow bubble into gray one with just css.
You could do that if you reversed transparent and colored parts, and filled whole square with color. Example: http://jsfiddle.net/Arministrator/j5gLgyt8/
#bubble_img{
background:yellow;
}
#bubble_img:hover{
background:#ff9f2d;
Or you can use two images (css sprites even better) as shown in one of the answers.
This may not be the exact answer you're looking for, but maybe you can consider using Font Awesome. It'll be a clean, sharp bubble and you can easily resize and color it anyway you want with CSS. Another route would be to use SVG.
http://jsfiddle.net/wilchow/39gud4bh/5/
.fa-bubble {
font-size: 140px;
color: #333333;
cursor: pointer;
}
.fa-bubble:hover {
color: #ff9f2d;
}
Just move the second image over the first and set opacity
#overlay {z-index:100;opacity:0.2;position:relative;left:-131px;top:-3px;
}
<div>
<img id="bubble" src="http://png-1.findicons.com/files/icons/2711/free_icons_for_windows8_metro/128/speech_bubble.png">
</img>
<img id="overlay" src="http://s30.postimg.org/lptvfyod9/speech_bubbleorange.png">
</div>
As far as I know there is no CSS property that will allow you change a gray colored image into a colored one.
However, the reverse is possible using CSS filters.
So if we reverse the 'process' and make the colored image appear grey by default we can remove that styling, perhaps on hover, to achieve the effect we are looking for.
#bubble {
-webkit-filter: grayscale(1) brightness(0.3);
}
#bubble:hover {
-webkit-filter: none
}
<div>
<img id="bubble" src="http://s30.postimg.org/lptvfyod9/speech_bubbleorange.png" />
</div>
Jsfiddle Comparison
NOTE: CSS filters are highly experimental and browser support is poor.
This is an experimental technology
Because this technology's
specification has not stabilized, check the compatibility table for
the proper prefixes to use in various browsers. Also note that the
syntax and behavior of an experimental technology is subject to change
in future versions of browsers as the spec changes
MDN Reference
CanIUse.com Reference

How to add transparent background color css to layerslider wp

As you can see from these screenshots: http://imgur.com/JUh6VVG and http://imgur.com/Sg7av0n I'm using layerslider wp and I'd like to make the background around the text transparent. You can see in the second screenshot that there's a place for custom css. What css should I put in there to make that happen? As always I appreciate the help.
Cheers!
You'll have to find the class or id of that div. Once you know that, you can use the following css:
.your-text-div {
background-color: transparent;
}

How can I make the background of elements of my blog transparent in Blogger?

On on my Blog (http://www.ourunitedvoice.org/) there is a great deal of empty white space that I want to change to be transparent so my background shows off more in my blog similar to this blog: http://wholefoodsmarket.com/blog/whole-story.
I don't know what HTML needs to be changed on these various page components to remove the white and make them see through. Hoping someone can help me!
add this to the body css:
body {
background-color:rgba(255,255,255,0);
}
The last "0" will make the background transparent
Sir you are using a png file
while the other site is using CSS
there is no magic learn some CSS and you will solve your problem