Firstly i would like to say hello, this is my first question ever and it's been bugging me for awhile. I'm a newbie at html coding and i'd like to keep learning, it's interesting. Anyways to the question.
When i try to move a textbox over an image it gets lost behind the image like this:
<div style="background-color:#x;width:500px;height:300px;"> </div>
<p><img alt="" src="x" style="width:800px;height:401px;margin-top:-400px;margin-left:"/></p>
not sure if this helps, but try using the z-index property
http://www.w3schools.com/cssref/pr_pos_z-index.asp
Maybe it is better to read the whole HTML tutorial on w3schools. http://www.w3schools.com/html/default.asp
If you want an image at the background of an text, set the image as a background!
Related
I want to make a button with the discord logo but when I try to add the anchor tag the text goes down a bit and it becomes uncentered.
Is there a way to fix this or a different way I should be approaching this?
HTML Code:
<li class="nav__btn">
Join our Discord
</li>
Try reading this to see if it could help out.
https://coder-coder.com/how-to-center-button-with-html-css/
I would assume it would work the same way with an image button. Also try experimenting with div tags.
You have mistake in your code here: "button" >< img class.
Better use button tag for this, see example button with icon.
Also, provide some screenshot what exactly do you need.
I'm trying to recreate the features section:<section id="features"> # https://dreem.com/en/
Basically, I'd like to change the background images and text and iconography.
I've been playing around with it here: https://codepen.io/JordiUp/pen/XZJdQO
But I haven't figured out how to the get the hove transitions working.
Am I able to achive this effect within just a section using HTML and CSS, or am i missing something and need Javascript.
First time posting, Huge thanks in advance.
Hope it will work for you, Please refer this link
https://www.tutorialrepublic.com/codelab.php?topic=faq&file=css-image-swap-on-hover
I'm using prettyphoto for the first time, very nice tool. I would like to know if more people have this problem. Its not crucial but I hate to not do things because I dont understand them. This is the code:
<div class="single_left">
<img src="_img/examples/thumb-1_50.jpg" alt="WHATEVER INFO" />
</div>
It works perfectly. But I have a doubt. If you look all the code you will see that its quite simpel. Its a div in which inside there is a <a> and inside there is a <img> thats acts as a thumbnail. As any for any <img> you need to add an alt="" atribute. The idea of this atribute is that if somebody has slow internet or if the image fails to load, a small description would be displayed in a text format, this will be the content of alt="". In this case "WHATEVER INFO" (Check code above). So if the image is displayed this alternative text shoud NOT be displayed.
ok... clear
The issue is that with prettyphoto if the picture is zoomed from a click you can see the alt="" text on top of the frame of prettyphoto. So in this case WHATEVER INFO would be displayed. This is not its purpose and of course breaks any design plan.
Does anybody know why this happens??
Is there a way of solving this so I can put some alternative text??
According to this link, add this CSS code to css/custom.css to do what you want:
div.ppt, .pp_description {
display: none !important;
}
I can let you know that the answer to my question os exactly like this:
div.ppt {
display: none !important;
}
This will make the alt value not displayed.
What I don;t know is if the picture is not loaded if the alt will work as such... At least you know how to take it out.
Greetings!!
I'm currently working on http://dawtano.com/pp/ , and I want to show off my work in the div's looking like two pieces of paper on top of each other, with an inside. But something is going wrong - I'm currently working out from the same code used on http://bestwebgallery.com (thumbnail-view) - I can't get the image to show inside, no matter what size or w/e, I'm lost.
replace
<img src"http://dawtano.com/pp/images/qillnet-s.png" alt="Qill.net" />
with
<img src="http://dawtano.com/pp/images/qillnet-s.png" alt="Qill.net" />
You forgot to put an "=" symbol.
in css it's background-image perhaps that's the problem?
try css="background-image:url('paper.png');"
Im new to programming..Can anybody help me out please ....
im using an html to display an image later i want to display another html on the first html so i need to set second html as transparent. so the image in the first html looks like a background image....
is it possible...?
Thanks
Well you actually could use an <iframe> containing the second page in a floating <div>-element. But as always, it's not always good just because it exists or because it was technically possible.
Except for the use of frame, you should never have more than one <html> and never more than one <body>
It would be the best to have something like this:
<html>
<head><!-- header goes here --></head>
<body style="background-image: url('first.png');">
<img src="second.png"/>
</body>
</html>
Sure you could extract the css-part into a css-file. And you could set the style-attribute for another tag as well, it doesn't forcibly has to be <body>
hope that helps a bit.
You can't. But if you just want a background image, you can accomplish this by using CSS and the background-image. See: http://www.w3schools.com/css/css_background.asp
With a scripting/programming language you can.
In ASP.NET you can read the contents of an html file and put it inside your current page.
It doesn't sound like iframe is what you are looking for. Perhaps the use of the words "on" and "transparent" are throwing me off. It sounds like you want to have two HTML pages, with the content from one appearing in front of the other but transparent? In that case I think CSS z-index might help you:
https://developer.mozilla.org/en/Understanding_CSS_z-index/Stacking_context_example_1