css how to use background-image [duplicate] - css

This question already has answers here:
CSS background-image - What is the correct usage?
(10 answers)
Closed 4 years ago.
background-image: url(../images/title2);
im also trying to apply it to a container
i have a rootfolder called learning project inside it looks like this
My html page is inside html and my css is inside css both called index I'm trying to get from my css to my image folder to title2 which is just a random name and it wont work
Can anyone help?

wrap the relative url in quotes
and thats it
background-image: url('../images/title2');

Related

Make a container transparent only when another div is over [duplicate]

This question already has answers here:
How to make a child div transparent?
(2 answers)
Closed 5 years ago.
So as exposed in the title, i'd like to make a part of a container transparent, but only where there is another div, I know I can't tell it clearly, then I made an example :
I don't know if it is possible doing this, using ONLY CSS, I can't use JQuery, not even Javascript.
Thank you in advance for your answers :)
No, this can't be done with CSS alone. However, as CBroe has said, you could apply the same background image to the second/inner to give the illusion that it's transparent.

How to apply css for html page in Iframe? [duplicate]

This question already has answers here:
How to apply CSS to iframe?
(28 answers)
Closed 6 years ago.
I've a DIV, inside that i've Iframe. In that Iframe i'm loading the Html page. So I want to apply the css for that Html page.
You want to change the style inside the Iframe... It is no possible, when you show an Iframe you can't modify his style.
If yu create the Iframe, apply the style modification before to show in any page

How to have a static background [duplicate]

This question already has an answer here:
HTML CSS Making the background image static
(1 answer)
Closed 8 years ago.
Does anyone know how to keep a constant background so that when you scroll down a page it seems like everything is moving but the background image...basically a static background.
It's a CSS attribute called background-attachment: fixed;
Use it with the background-image attribute within the same element.

Is it possible to alter the CSS of an iFrame? [duplicate]

This question already has answers here:
Override body style for content in an iframe
(11 answers)
Closed 9 years ago.
I would like to add, remove, and adjust the CSS of iFrame. In particular I am looking to to this to Disqus comments which embeds their comments into an iFrame on the page.
If I am allowed to modify the CSS of an iFrame is the only risk that I am susceptible to them (in this case Disqus) updating the CSS classes and ID's?
No, you can't.
You can edit it via JavaScript, but the iframe content and its parent need to be on the same domain, if not you will not be able to do it

CSS file-input hide path [duplicate]

This question already has answers here:
Closed 11 years ago.
Possible Duplicate:
How to hide text field in Html File Upload
Hi!Is it possible to hide the input-file path keeping just the browse button?
thanks
Luca
Unfortunately the file input isn't style-able, and it shows differently in each browser. So any solutions are sort of hacky, to say the least.
One solution is to place an image behind the input, and setting it's opacity to 0. See here for the tutorial that I follow.

Resources